]> git.ipfire.org Git - thirdparty/freeswitch.git/commitdiff
mod_sofia: use the register proxy for the R-URI on register when register-proxy is...
authorBrian West <brian@freeswitch.org>
Tue, 23 Jun 2009 17:52:46 +0000 (17:52 +0000)
committerBrian West <brian@freeswitch.org>
Tue, 23 Jun 2009 17:52:46 +0000 (17:52 +0000)
git-svn-id: http://svn.freeswitch.org/svn/freeswitch/trunk@13911 d0543943-73ff-0310-b7d9-9358b9ac24b2

src/mod/endpoints/mod_sofia/sofia.c

index 163ca791634fbc153bc59bd06e9c41359f64a463..fae5deac677788abe8499f1187c29738bbd6ea01 100644 (file)
@@ -1374,7 +1374,7 @@ static void parse_gateways(sofia_profile_t *profile, switch_xml_t gateways_tag)
                                params = switch_core_sprintf(gateway->pool, ";transport=%s", register_transport);
                        }
 
-                       gateway->register_url = switch_core_sprintf(gateway->pool, "sip:%s;transport=%s", proxy, register_transport);
+                       gateway->register_url = switch_core_sprintf(gateway->pool, "sip:%s;transport=%s", register_proxy ? register_proxy : proxy, register_transport);
                        gateway->register_from = switch_core_sprintf(gateway->pool, "<sip:%s@%s;transport=%s>", from_user, from_domain, register_transport);
 
                        sipip = contact_host ? contact_host : profile->extsipip ?  profile->extsipip : profile->sipip;