[asterisk-commits] simon.perreault: branch group/v6 r84404 - /team/group/v6/trunk/channels/

SVN commits to the Asterisk project asterisk-commits at lists.digium.com
Tue Oct 2 10:21:14 CDT 2007


Author: simon.perreault
Date: Tue Oct  2 10:21:14 2007
New Revision: 84404

URL: http://svn.digium.com/view/asterisk?view=rev&rev=84404
Log:
Instead of hardcoding IPv6 and IPv4 wildcard addresses (:: and 0.0.0.0), call getaddrinfo
with a NULL address.
Fixes https://www.viagenie.ca/bugzilla/show_bug.cgi?id=63.

Modified:
    team/group/v6/trunk/channels/chan_sip.c

Modified: team/group/v6/trunk/channels/chan_sip.c
URL: http://svn.digium.com/view/asterisk/team/group/v6/trunk/channels/chan_sip.c?view=diff&rev=84404&r1=84403&r2=84404
==============================================================================
--- team/group/v6/trunk/channels/chan_sip.c (original)
+++ team/group/v6/trunk/channels/chan_sip.c Tue Oct  2 10:21:14 2007
@@ -18618,10 +18618,9 @@
 		snprintf(sbuf, sizeof(sbuf), "%d", defport);
 		if (option_verbose > 1)
 			ast_verbose(VERBOSE_PREFIX_3 "No bindaddr specified in sip.conf. Binding to default addresses (0.0.0.0 and ::)\n");
-		if (ast_vinetsock_list_getaddrinfo(netsocks, "::", sbuf) <= 0)
-			ast_log(LOG_WARNING, "Unable to bind to ::\n");
-		if (ast_vinetsock_list_getaddrinfo(netsocks, "0.0.0.0", sbuf) <= 0)
-			ast_log(LOG_WARNING, "Unable to bind to 0.0.0.0\n");
+		if (ast_vinetsock_list_getaddrinfo(netsocks, NULL, sbuf) <= 0)
+			ast_log(LOG_WARNING, "Unable to bind to default addresses "
+					"(:: and 0.0.0.0)\n");
 	}
 	ast_mutex_lock(&netlock);
 	ast_vinetsock_list_bind(netsocks, io, global_tos_sip, sipsock_read, NULL, 1, "SIP");




More information about the asterisk-commits mailing list