Commit 5283278e authored by Ghislain MARY's avatar Ghislain MARY
Browse files

Fix 2 memory leaks.

parent f07be6ec
......@@ -658,6 +658,7 @@ static void linphone_call_get_local_ip(LinphoneCall *call, const LinphoneAddress
if (err == 0) {
dest = domain;
}
if (res != NULL) freeaddrinfo(res);
}
if (linphone_core_get_firewall_policy(call->core)==LinphonePolicyUseNatAddress
&& (ip=linphone_core_get_nat_address_resolved(call->core))!=NULL){
......
......@@ -3528,6 +3528,7 @@ static int remote_address_compare(LinphoneCall *call, const LinphoneAddress *rad
LinphoneCall *linphone_core_get_call_by_remote_address(LinphoneCore *lc, const char *remote_address){
LinphoneAddress *raddr=linphone_address_new(remote_address);
MSList *elem=ms_list_find_custom(lc->calls,(int (*)(const void*,const void *))remote_address_compare,raddr);
linphone_address_unref(raddr);
if (elem) return (LinphoneCall*) elem->data;
return NULL;
}
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment