[asterisk-commits] simon.perreault: branch group/v6-new r273895 - /team/group/v6-new/main/dnsmgr.c

SVN commits to the Asterisk project asterisk-commits at lists.digium.com
Mon Jul 5 09:16:32 CDT 2010


Author: simon.perreault
Date: Mon Jul  5 09:16:28 2010
New Revision: 273895

URL: http://svnview.digium.com/svn/asterisk?view=rev&rev=273895
Log:
Only set port if SRV lookup did not set it first

Modified:
    team/group/v6-new/main/dnsmgr.c

Modified: team/group/v6-new/main/dnsmgr.c
URL: http://svnview.digium.com/svn/asterisk/team/group/v6-new/main/dnsmgr.c?view=diff&rev=273895&r1=273894&r2=273895
==============================================================================
--- team/group/v6-new/main/dnsmgr.c (original)
+++ team/group/v6-new/main/dnsmgr.c Mon Jul  5 09:16:28 2010
@@ -157,7 +157,8 @@
 	memset(&tmp, 0, sizeof(tmp));
 
 	if (!ast_get_ip_or_srv(&tmp, entry->name, entry->service)) {
-		ast_sockaddr_set_port(&tmp, ast_sockaddr_port(entry->result));
+		if (!ast_sockaddr_port(&tmp))
+			ast_sockaddr_set_port(&tmp, ast_sockaddr_port(entry->result));
 		if(ast_sockaddr_cmp(&tmp, entry->result)) {
 			ast_log(LOG_NOTICE, "dnssrv: host '%s' changed from %s to %s\n",
 					entry->name, ast_sockaddr_stringify(entry->result),




More information about the asterisk-commits mailing list