mirror of
https://gitlab.linphone.org/BC/public/linphone-iphone.git
synced 2026-05-03 20:46:28 +00:00
fix crash and bug around presence list subscription
This commit is contained in:
parent
09e861e19e
commit
3322463148
2 changed files with 9 additions and 5 deletions
|
|
@ -976,11 +976,12 @@ void linphone_friend_list_export_friends_as_vcard4_file(LinphoneFriendList *list
|
|||
|
||||
void linphone_friend_list_enable_subscriptions(LinphoneFriendList *list, bool_t enabled) {
|
||||
if (list->enable_subscriptions != enabled) {
|
||||
list->enable_subscriptions = enabled;
|
||||
if (enabled) {
|
||||
linphone_friend_list_update_subscriptions(list, NULL, TRUE);
|
||||
} else {
|
||||
linphone_friend_list_close_subscriptions(list);
|
||||
}
|
||||
list->enable_subscriptions = enabled;
|
||||
|
||||
}
|
||||
}
|
||||
|
|
|
|||
|
|
@ -633,12 +633,15 @@ char* linphone_proxy_config_normalize_phone_number(LinphoneProxyConfig *proxy, c
|
|||
LinphoneProxyConfig *tmpproxy = proxy ? proxy : linphone_proxy_config_new();
|
||||
char* result = NULL;
|
||||
if (linphone_proxy_config_is_phone_number(tmpproxy, username)){
|
||||
LinphoneDialPlan dialplan = *linphone_dial_plan_by_ccc(tmpproxy->dial_prefix); //copy dial plan;
|
||||
char * flatten=flatten_number(username);
|
||||
LinphoneDialPlan dialplan = *linphone_dial_plan_by_ccc(tmpproxy->dial_prefix); //copy dial plan
|
||||
ms_debug("Flattened number is '%s' for '%s'",flatten, username);
|
||||
if (strcmp(tmpproxy->dial_prefix,dialplan.ccc)!=0){
|
||||
//probably generic dialplan, preserving proxy dial prefix
|
||||
strcpy(dialplan.ccc,tmpproxy->dial_prefix);
|
||||
|
||||
if (tmpproxy->dial_prefix){
|
||||
if (strcmp(tmpproxy->dial_prefix,dialplan.ccc) != 0){
|
||||
//probably generic dialplan, preserving proxy dial prefix
|
||||
strcpy(dialplan.ccc,tmpproxy->dial_prefix);
|
||||
}
|
||||
}
|
||||
/*if proxy has a dial prefix, modify phonenumber accordingly*/
|
||||
if (tmpproxy->dial_prefix!=NULL && tmpproxy->dial_prefix[0]!='\0'){
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue