[svn-commits] elguero: trunk r362266 - in /trunk: ./ channels/chan_sip.c

SVN commits to the Digium repositories svn-commits at lists.digium.com
Tue Apr 17 10:00:06 CDT 2012


Author: elguero
Date: Tue Apr 17 10:00:02 2012
New Revision: 362266

URL: http://svnview.digium.com/svn/asterisk?view=rev&rev=362266
Log:
Turn off warning message when bind address is set to any.

When a bind address is set to an ANY address (udpbindport=::), a warning message
is displayed stating that "Address remapping activated in sip.conf but we're
using IPv6, which doesn't need it.  Please remove 'localnet' and/or 'externaddr'
settings."  But if one is running dual stack, we shouldn't be told to turn those
settings off.

This patch checks if the bind address is an ANY address or not.  The warning
message will now only be displayed if the bind address is NOT an ANY address and
IPv6 is being used.

Also, updated the copyright year.

(closes issue ASTERISK-19456) 
Reported by: Michael L. Young 
Tested by: Michael L. Young 
Patches: 
  chan_sip_ipv6_message.diff uploaded by Michael L. Young (license 5026)
........

Merged revisions 362253 from http://svn.asterisk.org/svn/asterisk/branches/1.8
........

Merged revisions 362264 from http://svn.asterisk.org/svn/asterisk/branches/10

Modified:
    trunk/   (props changed)
    trunk/channels/chan_sip.c

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

Modified: trunk/channels/chan_sip.c
URL: http://svnview.digium.com/svn/asterisk/trunk/channels/chan_sip.c?view=diff&rev=362266&r1=362265&r2=362266
==============================================================================
--- trunk/channels/chan_sip.c (original)
+++ trunk/channels/chan_sip.c Tue Apr 17 10:00:02 2012
@@ -1,7 +1,7 @@
 /*
  * Asterisk -- An open source telephony toolkit.
  *
- * Copyright (C) 1999 - 2006, Digium, Inc.
+ * Copyright (C) 1999 - 2012, Digium, Inc.
  *
  * Mark Spencer <markster at digium.com>
  *
@@ -3442,7 +3442,7 @@
 	ast_sockaddr_copy(&theirs, them);
 
 	if (ast_sockaddr_is_ipv6(&theirs)) {
-		if (localaddr && !ast_sockaddr_isnull(&externaddr)) {
+		if (localaddr && !ast_sockaddr_isnull(&externaddr) && !ast_sockaddr_is_any(&bindaddr)) {
 			ast_log(LOG_WARNING, "Address remapping activated in sip.conf "
 				"but we're using IPv6, which doesn't need it. Please "
 				"remove \"localnet\" and/or \"externaddr\" settings.\n");




More information about the svn-commits mailing list