mirror of
https://gitlab.linphone.org/BC/public/linphone-iphone.git
synced 2026-01-20 04:28:10 +00:00
tester: accountmanager should temporary deal with both old and new flexisip servers
This commit is contained in:
parent
5103872027
commit
47e3693511
1 changed files with 11 additions and 0 deletions
|
|
@ -112,6 +112,15 @@ static void account_created_on_server_cb(LinphoneCore *lc, LinphoneProxyConfig *
|
|||
}
|
||||
}
|
||||
|
||||
// TEMPORARY CODE: remove function below when flexisip is updated, this is not needed anymore!
|
||||
// The new flexisip now answer "200 Test account created" when creating a test account, and do not
|
||||
// challenge authentication anymore! so this code is not used for newer version
|
||||
static void account_created_auth_requested_cb(LinphoneCore *lc, const char *username, const char *realm, const char *domain){
|
||||
Account *account=(Account*)linphone_core_get_user_data(lc);
|
||||
account->created=1;
|
||||
}
|
||||
// TEMPORARY CODE: remove line above when flexisip is updated, this is not needed anymore!
|
||||
|
||||
void account_create_on_server(Account *account, const LinphoneProxyConfig *refcfg){
|
||||
LinphoneCoreVTable vtable={0};
|
||||
LinphoneCore *lc;
|
||||
|
|
@ -123,6 +132,8 @@ void account_create_on_server(Account *account, const LinphoneProxyConfig *refcf
|
|||
LCSipTransports tr;
|
||||
|
||||
vtable.registration_state_changed=account_created_on_server_cb;
|
||||
// TEMPORARY CODE: remove line below when flexisip is updated, this is not needed anymore!
|
||||
vtable.auth_info_requested=account_created_auth_requested_cb;
|
||||
lc=configure_lc_from(&vtable,bc_tester_get_resource_dir_prefix(),NULL,account);
|
||||
tr.udp_port=LC_SIP_TRANSPORT_RANDOM;
|
||||
tr.tcp_port=LC_SIP_TRANSPORT_RANDOM;
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue