[Freeswitch-svn] [commit] r10541 - freeswitch/trunk/src/mod/endpoints/mod_sofia

FreeSWITCH SVN anthm at freeswitch.org
Wed Nov 26 09:59:16 PST 2008


Author: anthm
Date: Wed Nov 26 12:59:14 2008
New Revision: 10541

Log:
patch for SFSIP-104

Modified:
   freeswitch/trunk/src/mod/endpoints/mod_sofia/sofia_presence.c

Modified: freeswitch/trunk/src/mod/endpoints/mod_sofia/sofia_presence.c
==============================================================================
--- freeswitch/trunk/src/mod/endpoints/mod_sofia/sofia_presence.c	(original)
+++ freeswitch/trunk/src/mod/endpoints/mod_sofia/sofia_presence.c	Wed Nov 26 12:59:14 2008
@@ -1542,13 +1542,18 @@
 			char *sticky = NULL;
 
 			if (is_nat) {
+				char params[128] = "";
+				if (contact->m_url->url_params) {
+					switch_snprintf(params, sizeof(params), ";%s", contact->m_url->url_params);
+				}
 				ipv6 = strchr(network_ip, ':');
-				sticky = switch_mprintf("sip:%s@%s%s%s:%d",
+				sticky = switch_mprintf("sip:%s@%s%s%s:%d%s",
 										contact_user,
 										ipv6 ? "[" : "",
 										network_ip,
 										ipv6 ? "]" : "",
-										network_port);
+										network_port,
+										params);
 			}
 
 			nua_respond(nh, SIP_202_ACCEPTED, NUTAG_WITH_THIS(nua), SIPTAG_SUBSCRIPTION_STATE_STR(sstr), TAG_IF(sticky, NUTAG_PROXY(sticky)),



More information about the Freeswitch-svn mailing list