[asterisk-commits] dvossel: branch 1.6.0 r221712 - /branches/1.6.0/channels/chan_sip.c

SVN commits to the Asterisk project asterisk-commits at lists.digium.com
Thu Oct 1 15:19:13 CDT 2009


Author: dvossel
Date: Thu Oct  1 15:19:08 2009
New Revision: 221712

URL: http://svnview.digium.com/svn/asterisk?view=rev&rev=221712
Log:
Fixes issue with non dynamic hosts not being set for peers

Modified:
    branches/1.6.0/channels/chan_sip.c

Modified: branches/1.6.0/channels/chan_sip.c
URL: http://svnview.digium.com/svn/asterisk/branches/1.6.0/channels/chan_sip.c?view=diff&rev=221712&r1=221711&r2=221712
==============================================================================
--- branches/1.6.0/channels/chan_sip.c (original)
+++ branches/1.6.0/channels/chan_sip.c Thu Oct  1 15:19:08 2009
@@ -21453,18 +21453,18 @@
 							peer->defaddr.sin_port = peer->addr.sin_port;
 							peer->addr.sin_port = 0;
 						}
-						peer->host_dynamic = TRUE;
-					} else {
-						/* Non-dynamic.  Make sure we become that way if we're not */
-						AST_SCHED_DEL(sched, peer->expire);
-						peer->host_dynamic = FALSE;
-						srvlookup = v->value;
-						if (global_dynamic_exclude_static) {
-							int err = 0;
-							global_contact_ha = ast_append_ha("deny", (char *)ast_inet_ntoa(peer->addr.sin_addr), global_contact_ha, &err);
-							if (err) {
-								ast_log(LOG_ERROR, "Bad ACL entry in configuration line %d : %s\n", v->lineno, v->value);
-							}
+					}
+					peer->host_dynamic = TRUE;
+				} else {
+					/* Non-dynamic.  Make sure we become that way if we're not */
+					AST_SCHED_DEL(sched, peer->expire);
+					peer->host_dynamic = FALSE;
+					srvlookup = v->value;
+					if (global_dynamic_exclude_static) {
+						int err = 0;
+						global_contact_ha = ast_append_ha("deny", (char *)ast_inet_ntoa(peer->addr.sin_addr), global_contact_ha, &err);
+						if (err) {
+							ast_log(LOG_ERROR, "Bad ACL entry in configuration line %d : %s\n", v->lineno, v->value);
 						}
 					}
 				}




More information about the asterisk-commits mailing list