From: Brian West Date: Thu, 25 Jun 2009 16:50:13 +0000 (+0000) Subject: mod_sofia: do not set route_uri unless there is actually one to go to. X-Git-Tag: v1.0.4~335 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=f68a0016d530ac304c11fdb734e020233a305c77;p=thirdparty%2Ffreeswitch.git mod_sofia: do not set route_uri unless there is actually one to go to. git-svn-id: http://svn.freeswitch.org/svn/freeswitch/trunk@13952 d0543943-73ff-0310-b7d9-9358b9ac24b2 --- diff --git a/src/mod/endpoints/mod_sofia/sofia_glue.c b/src/mod/endpoints/mod_sofia/sofia_glue.c index 8a89a5a3b6..c0abd47a44 100644 --- a/src/mod/endpoints/mod_sofia/sofia_glue.c +++ b/src/mod/endpoints/mod_sofia/sofia_glue.c @@ -4162,13 +4162,8 @@ sofia_destination_t* sofia_glue_get_destination(char *data) *p = '\0'; } while ((--p > route_uri) && *p == ' '); } - } - else { - if(!(route_uri = strdup(contact))) { - goto mem_fail; - } - } - + } + if (!(to = strdup(data))) { goto mem_fail; }