mirror of
https://gitlab.linphone.org/BC/public/linphone-iphone.git
synced 2026-02-07 14:18:25 +00:00
tester: add --disable-tls-support option
This commit is contained in:
parent
be38b3474c
commit
943d2702e2
3 changed files with 16 additions and 9 deletions
|
|
@ -212,6 +212,7 @@ static const char* liblinphone_helper =
|
|||
"\t\t\t--dns-hosts </etc/hosts -like file to used to override DNS names (default: tester_hosts)>\n"
|
||||
"\t\t\t--keep-recorded-files\n"
|
||||
"\t\t\t--disable-leak-detector\n"
|
||||
"\t\t\t--disable-tls-support\n"
|
||||
"\t\t\t--6\n"
|
||||
;
|
||||
|
||||
|
|
@ -252,6 +253,8 @@ int main (int argc, char *argv[])
|
|||
liblinphone_tester_keep_recorded_files(TRUE);
|
||||
} else if (strcmp(argv[i],"--disable-leak-detector")==0){
|
||||
liblinphone_tester_disable_leak_detector(TRUE);
|
||||
} else if (strcmp(argv[i],"--disable-tls-support")==0){
|
||||
liblinphone_tester_tls_support_disabled = TRUE;
|
||||
} else if (strcmp(argv[i],"--6")==0){
|
||||
liblinphonetester_ipv6=TRUE;
|
||||
} else {
|
||||
|
|
|
|||
|
|
@ -110,6 +110,9 @@ extern const char* test_username;
|
|||
extern const char* test_password;
|
||||
extern const char* test_route;
|
||||
extern const char* userhostsfile;
|
||||
extern bool_t liblinphone_tester_tls_support_disabled;
|
||||
extern const MSAudioDiffParams audio_cmp_params;
|
||||
extern const char *liblinphone_tester_mire_id;
|
||||
extern bool_t liblinphonetester_ipv6;
|
||||
|
||||
typedef struct _stats {
|
||||
|
|
@ -368,8 +371,6 @@ void _call_with_ice_base(LinphoneCoreManager* pauline,LinphoneCoreManager* marie
|
|||
void check_nb_media_starts(LinphoneCoreManager *caller, LinphoneCoreManager *callee, unsigned int caller_nb_media_starts, unsigned int callee_nb_media_starts);
|
||||
void record_call(const char *filename, bool_t enableVideo, const char *video_codec);
|
||||
|
||||
extern const MSAudioDiffParams audio_cmp_params;
|
||||
|
||||
/*
|
||||
* this function return max value in the last 3 seconds*/
|
||||
int linphone_core_manager_get_max_audio_down_bw(const LinphoneCoreManager *mgr);
|
||||
|
|
@ -390,8 +391,6 @@ void check_nb_media_starts(LinphoneCoreManager *caller, LinphoneCoreManager *cal
|
|||
LinphoneConferenceServer* linphone_conference_server_new(const char *rc_file, bool_t do_registration);
|
||||
void linphone_conference_server_destroy(LinphoneConferenceServer *conf_srv);
|
||||
|
||||
extern const char *liblinphone_tester_mire_id;
|
||||
|
||||
LinphoneAddress * linphone_core_manager_resolve(LinphoneCoreManager *mgr, const LinphoneAddress *source);
|
||||
FILE *sip_start(const char *senario, const char* dest_username, const char *passwd, LinphoneAddress* dest_addres);
|
||||
|
||||
|
|
|
|||
|
|
@ -45,6 +45,7 @@
|
|||
static int liblinphone_tester_keep_accounts_flag = 0;
|
||||
static int liblinphone_tester_keep_record_files = FALSE;
|
||||
static int liblinphone_tester_leak_detector_disabled = FALSE;
|
||||
bool_t liblinphone_tester_tls_support_disabled = FALSE;
|
||||
int manager_count = 0;
|
||||
int leaked_objects_count = 0;
|
||||
const MSAudioDiffParams audio_cmp_params = {10,2000};
|
||||
|
|
@ -262,11 +263,15 @@ LinphoneCoreManager *get_manager(LinphoneCore *lc){
|
|||
}
|
||||
|
||||
bool_t transport_supported(LinphoneTransportType transport) {
|
||||
Sal *sal = sal_init(NULL);
|
||||
bool_t supported = sal_transport_available(sal,(SalTransport)transport);
|
||||
if (!supported) ms_message("TLS transport not supported, falling back to TCP if possible otherwise skipping test.");
|
||||
sal_uninit(sal);
|
||||
return supported;
|
||||
if ((transport == LinphoneTransportDtls || transport == LinphoneTransportTls) && liblinphone_tester_tls_support_disabled == TRUE) {
|
||||
return FALSE;
|
||||
} else {
|
||||
Sal *sal = sal_init(NULL);
|
||||
bool_t supported = sal_transport_available(sal,(SalTransport)transport);
|
||||
if (!supported) ms_message("TLS transport not supported, falling back to TCP if possible otherwise skipping test.");
|
||||
sal_uninit(sal);
|
||||
return supported;
|
||||
}
|
||||
}
|
||||
|
||||
#if __clang__ || ((__GNUC__ == 4 && __GNUC_MINOR__ >= 6) || __GNUC__ > 4)
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue