[asterisk-commits] file: trunk r188247 - /trunk/channels/chan_sip.c

SVN commits to the Asterisk project asterisk-commits at lists.digium.com
Tue Apr 14 08:14:25 CDT 2009


Author: file
Date: Tue Apr 14 08:14:21 2009
New Revision: 188247

URL: http://svn.digium.com/svn-view/asterisk?view=rev&rev=188247
Log:
Fix a bug with the change I made yesterday to outbound proxy support.

Per discussion with oej on IRC we need the actual IP address, not the
outbound proxy IP address, in the sa field. Upon further inspection
this should make the behaviour of all other uses of the outbound proxy
in the code.

Modified:
    trunk/channels/chan_sip.c

Modified: trunk/channels/chan_sip.c
URL: http://svn.digium.com/svn-view/asterisk/trunk/channels/chan_sip.c?view=diff&rev=188247&r1=188246&r2=188247
==============================================================================
--- trunk/channels/chan_sip.c (original)
+++ trunk/channels/chan_sip.c Tue Apr 14 08:14:21 2009
@@ -5002,11 +5002,7 @@
 	/* Get the outbound proxy information */
 	ref_proxy(dialog, obproxy_get(dialog, NULL));
 
-	if (dialog->outboundproxy) {
-		/* If we have an outbound proxy, don't bother with DNS resolution at all, but set the port */
-		portno = port ? atoi(port) : (dialog->socket.type & SIP_TRANSPORT_TLS) ? STANDARD_TLS_PORT : STANDARD_SIP_PORT;
-		memcpy(&dialog->sa.sin_addr, &dialog->outboundproxy->ip.sin_addr, sizeof(dialog->sa.sin_addr));
-	} else if (sin) {
+	if (sin) {
 		/* This address should be updated using dnsmgr */
 		memcpy(&dialog->sa.sin_addr, &sin->sin_addr, sizeof(dialog->sa.sin_addr));
 		if (!sin->sin_port) {




More information about the asterisk-commits mailing list