[svn-commits] oej: branch oej/pgtips-srv-and-outbound-stuff-1.8 r421669 - /team/oej/pgtips-...

SVN commits to the Digium repositories svn-commits at lists.digium.com
Thu Aug 21 07:13:18 CDT 2014


Author: oej
Date: Thu Aug 21 07:13:13 2014
New Revision: 421669

URL: http://svnview.digium.com/svn/asterisk?view=rev&rev=421669
Log:
Don't forget the port.

Modified:
    team/oej/pgtips-srv-and-outbound-stuff-1.8/channels/chan_sip.c

Modified: team/oej/pgtips-srv-and-outbound-stuff-1.8/channels/chan_sip.c
URL: http://svnview.digium.com/svn/asterisk/team/oej/pgtips-srv-and-outbound-stuff-1.8/channels/chan_sip.c?view=diff&rev=421669&r1=421668&r2=421669
==============================================================================
--- team/oej/pgtips-srv-and-outbound-stuff-1.8/channels/chan_sip.c (original)
+++ team/oej/pgtips-srv-and-outbound-stuff-1.8/channels/chan_sip.c Thu Aug 21 07:13:13 2014
@@ -5847,11 +5847,11 @@
 					ast_debug(3, "   ==> Trying SRV entry %d (prio %d weight %d): %s\n", rec, prio, weight, hostn);
 					/* XXX We need to try all IP addresses if there are multiple A / AAAA records*/
 					if (!ast_sockaddr_resolve_first_transport(&dialog->sa, hostn, 0, dialog->socket.type ? dialog->socket.type : SIP_TRANSPORT_UDP)) {
+						/* Make sure we set the port */
+						ast_sockaddr_set_port(&dialog->sa, port);
 						/* We found a host to try on */
 						break;
 					}
-					/* Make sure we set the port */
-					ast_sockaddr_set_port(&dialog->sa, port);
 		
 				}
 
@@ -13941,7 +13941,7 @@
 			return 0;
 		}
 
-		if (!ast_sockaddr_port(&r->us) && !r->dnsmgr && r->portno) {
+		if (!ast_sockaddr_port(&p->sa) && !r->dnsmgr && r->portno) {
 			ast_sockaddr_set_port(&p->sa, r->portno);
 			ast_sockaddr_set_port(&p->recv, r->portno);
 			ast_debug(2, "Confusing code set port to %d\n", r->portno);




More information about the svn-commits mailing list