[asterisk-commits] oej: branch oej/oolong-path-support-trunk r380449 - /team/oej/oolong-path-sup...

SVN commits to the Asterisk project asterisk-commits at lists.digium.com
Wed Jan 30 06:50:18 CST 2013


Author: oej
Date: Wed Jan 30 06:50:14 2013
New Revision: 380449

URL: http://svnview.digium.com/svn/asterisk?view=rev&rev=380449
Log:
Make sure OPTIONs requests use the path too

Modified:
    team/oej/oolong-path-support-trunk/channels/chan_sip.c

Modified: team/oej/oolong-path-support-trunk/channels/chan_sip.c
URL: http://svnview.digium.com/svn/asterisk/team/oej/oolong-path-support-trunk/channels/chan_sip.c?view=diff&rev=380449&r1=380448&r2=380449
==============================================================================
--- team/oej/oolong-path-support-trunk/channels/chan_sip.c (original)
+++ team/oej/oolong-path-support-trunk/channels/chan_sip.c Wed Jan 30 06:50:14 2013
@@ -29616,6 +29616,10 @@
 	ast_copy_flags(&p->flags[1], &peer->flags[1], SIP_PAGE2_FLAGS_TO_COPY);
 	ast_copy_flags(&p->flags[2], &peer->flags[2], SIP_PAGE3_FLAGS_TO_COPY);
 	copy_route(&p->route, peer->path);
+	if (p->route) {
+		/* Parse SIP URI of first route-set hop and use it as target address */
+		__set_address_from_contact(p->route->hop, &p->sa, p->socket.type == SIP_TRANSPORT_TLS ? 1 : 0);	
+	}
 
 	/* Send OPTIONs to peer's fullcontact */
 	if (!ast_strlen_zero(peer->fullcontact)) {




More information about the asterisk-commits mailing list