From abc0561441df285f3a093db609b4d317c3996df8 Mon Sep 17 00:00:00 2001 From: Jehan Monnier Date: Thu, 21 Feb 2013 11:08:52 +0100 Subject: [PATCH] make sure local ip is only guessed by core in case of upnp --- coreapi/proxy.c | 11 +++++++---- 1 file changed, 7 insertions(+), 4 deletions(-) diff --git a/coreapi/proxy.c b/coreapi/proxy.c index 47a7cdd57..706e93456 100644 --- a/coreapi/proxy.c +++ b/coreapi/proxy.c @@ -277,13 +277,16 @@ static char *guess_contact_for_register(LinphoneProxyConfig *obj){ localip = linphone_upnp_context_get_external_ipaddress(obj->lc->upnp); localport = linphone_upnp_context_get_external_port(obj->lc->upnp); } -#endif //BUILD_UPNP -#ifndef USE_BELLESIP - else { +#endif //BUILD_UPNP +#ifdef USE_BELLESIP +#ifdef BUILD_UPNP + else +#endif /*BUILD_UPNP*/ + { linphone_address_destroy(contact); return NULL; } -#endif +#endif /*USE_BELLESIP*/ if(localip == NULL) { localip = localip_tmp; linphone_core_get_local_ip(obj->lc,host,localip_tmp);