mirror of
https://gitlab.linphone.org/BC/public/linphone-iphone.git
synced 2026-01-17 11:08:06 +00:00
Multiaccount: do not flush every auth infos if possible (wip)
This commit is contained in:
parent
42fbfcd74a
commit
03ab5ea9bf
2 changed files with 11 additions and 7 deletions
|
|
@ -508,13 +508,13 @@ extern void linphone_iphone_log_handler(int lev, const char *fmt, va_list args);
|
|||
linphone_proxy_config_enable_avpf(proxyCfg, use_avpf);
|
||||
linphone_proxy_config_set_expires(proxyCfg, expire);
|
||||
|
||||
LinphoneAuthInfo *proxyAi = linphone_proxy_config_find_auth_info(proxyCfg);
|
||||
// setup auth info
|
||||
if (linphone_core_get_auth_info_list(lc)) {
|
||||
info = linphone_auth_info_clone(linphone_core_get_auth_info_list(lc)->data);
|
||||
linphone_auth_info_set_username(info, username.UTF8String);
|
||||
if (proxyAi) {
|
||||
linphone_auth_info_set_username(proxyAi, username.UTF8String);
|
||||
if (password) {
|
||||
linphone_auth_info_set_passwd(info, password);
|
||||
linphone_auth_info_set_ha1(info, NULL);
|
||||
linphone_auth_info_set_passwd(proxyAi, password);
|
||||
linphone_auth_info_set_ha1(proxyAi, NULL);
|
||||
}
|
||||
linphone_auth_info_set_domain(info, linphone_proxy_config_get_domain(proxyCfg));
|
||||
} else {
|
||||
|
|
@ -834,8 +834,12 @@ extern void linphone_iphone_log_handler(int lev, const char *fmt, va_list args);
|
|||
LinphoneCore *lc = [LinphoneManager getLc];
|
||||
LinphoneProxyConfig *config = ms_list_nth_data(linphone_core_get_proxy_config_list(lc),
|
||||
[self integerForKey:@"current_proxy_config_preference"]);
|
||||
|
||||
const LinphoneAuthInfo *ai = linphone_proxy_config_find_auth_info(config);
|
||||
if (ai) {
|
||||
linphone_core_remove_auth_info(lc, ai);
|
||||
}
|
||||
linphone_core_remove_proxy_config(lc, config);
|
||||
linphone_core_clear_all_auth_info(lc); // TODO: only remove the right one
|
||||
[self transformLinphoneCoreToKeys];
|
||||
}
|
||||
@end
|
||||
|
|
|
|||
|
|
@ -1 +1 @@
|
|||
Subproject commit 2021ae9f8cc3435449a34d8a1dcaeffb2bdea931
|
||||
Subproject commit 725b8665663f753b28d3c6892949a8c4157abf66
|
||||
Loading…
Add table
Reference in a new issue