[asterisk-commits] file: trunk r425133 - in /trunk: ./ res/res_pjsip_nat.c

SVN commits to the Asterisk project asterisk-commits at lists.digium.com
Fri Oct 10 07:10:55 CDT 2014


Author: file
Date: Fri Oct 10 07:10:53 2014
New Revision: 425133

URL: http://svnview.digium.com/svn/asterisk?view=rev&rev=425133
Log:
res_pjsip_nat: Place source port into rport of responses if 'force_rport' is on.

When the 'force_rport' option is enabled the behavior should be the same
as if the remote side placed rport into the message themselves. Therefore
any responses we send should include the source port of the request in the
rport of the Via header.

#SIPit31

ASTERISK-24387 #close
Reported by: Matt Jordan
........

Merged revisions 425131 from http://svn.asterisk.org/svn/asterisk/branches/12
........

Merged revisions 425132 from http://svn.asterisk.org/svn/asterisk/branches/13

Modified:
    trunk/   (props changed)
    trunk/res/res_pjsip_nat.c

Propchange: trunk/
------------------------------------------------------------------------------
Binary property 'branch-13-merged' - no diff available.

Modified: trunk/res/res_pjsip_nat.c
URL: http://svnview.digium.com/svn/asterisk/trunk/res/res_pjsip_nat.c?view=diff&rev=425133&r1=425132&r2=425133
==============================================================================
--- trunk/res/res_pjsip_nat.c (original)
+++ trunk/res/res_pjsip_nat.c Fri Oct 10 07:10:53 2014
@@ -62,7 +62,7 @@
 	}
 
 	if (endpoint->nat.force_rport) {
-		rdata->msg_info.via->rport_param = 0;
+		rdata->msg_info.via->rport_param = rdata->pkt_info.src_port;
 	}
 
 	return PJ_FALSE;




More information about the asterisk-commits mailing list