mirror of
https://gitlab.linphone.org/BC/public/linphone-iphone.git
synced 2026-01-28 08:39:20 +00:00
proxy.c: we must also UNREGISTER when being in state RegistrationInProgress so that even if registration is pending we unregister properly
This commit is contained in:
parent
e001e61c58
commit
31a77583d7
2 changed files with 6 additions and 4 deletions
|
|
@ -5941,7 +5941,8 @@ void sip_config_uninit(LinphoneCore *lc)
|
|||
sal_iterate(lc->sal);
|
||||
for(elem=config->proxies;elem!=NULL;elem=ms_list_next(elem)){
|
||||
LinphoneProxyConfig *cfg=(LinphoneProxyConfig*)(elem->data);
|
||||
still_registered|=linphone_proxy_config_is_registered(cfg);
|
||||
LinphoneRegistrationState state = linphone_proxy_config_get_state(cfg);
|
||||
still_registered|=(state==LinphoneRegistrationOk||state==LinphoneRegistrationProgress);
|
||||
}
|
||||
ms_usleep(100000);
|
||||
}
|
||||
|
|
|
|||
|
|
@ -402,9 +402,10 @@ LinphoneAddress *guess_contact_for_register(LinphoneProxyConfig *cfg){
|
|||
return ret;
|
||||
}
|
||||
|
||||
void _linphone_proxy_config_unregister(LinphoneProxyConfig *cfg) {
|
||||
if (cfg->op && cfg->state == LinphoneRegistrationOk) {
|
||||
sal_unregister(cfg->op);
|
||||
void _linphone_proxy_config_unregister(LinphoneProxyConfig *obj) {
|
||||
if (obj->op && (obj->state == LinphoneRegistrationOk ||
|
||||
(obj->state == LinphoneRegistrationProgress && obj->expires != 0))) {
|
||||
sal_unregister(obj->op);
|
||||
}
|
||||
}
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue