mirror of
https://gitlab.linphone.org/BC/public/linphone-iphone.git
synced 2026-01-20 12:38:09 +00:00
proxy.c: fix crash regression from cddb9c3, list copy is actually required
This commit is contained in:
parent
505c9104b2
commit
d697939bbe
1 changed files with 3 additions and 1 deletions
|
|
@ -1232,10 +1232,12 @@ void linphone_core_remove_proxy_config(LinphoneCore *lc, LinphoneProxyConfig *cf
|
|||
}
|
||||
|
||||
void linphone_core_clear_proxy_config(LinphoneCore *lc){
|
||||
const MSList* list=linphone_core_get_proxy_config_list(lc);
|
||||
MSList* list=ms_list_copy(linphone_core_get_proxy_config_list((const LinphoneCore*)lc));
|
||||
MSList* copy=list;
|
||||
for(;list!=NULL;list=list->next){
|
||||
linphone_core_remove_proxy_config(lc,(LinphoneProxyConfig *)list->data);
|
||||
}
|
||||
ms_list_free(copy);
|
||||
linphone_proxy_config_write_all_to_config_file(lc);
|
||||
}
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue