[asterisk-commits] file: branch 1.2 r52360 - /branches/1.2/channels/chan_iax2.c

asterisk-commits at lists.digium.com asterisk-commits at lists.digium.com
Fri Jan 26 17:03:24 MST 2007


Author: file
Date: Fri Jan 26 18:03:23 2007
New Revision: 52360

URL: http://svn.digium.com/view/asterisk?view=rev&rev=52360
Log:
Make the last context entry read in the dominant one. (issue #8918 reported by pj)

Modified:
    branches/1.2/channels/chan_iax2.c

Modified: branches/1.2/channels/chan_iax2.c
URL: http://svn.digium.com/view/asterisk/branches/1.2/channels/chan_iax2.c?view=diff&rev=52360&r1=52359&r2=52360
==============================================================================
--- branches/1.2/channels/chan_iax2.c (original)
+++ branches/1.2/channels/chan_iax2.c Fri Jan 26 18:03:23 2007
@@ -8359,13 +8359,11 @@
 				maskfound++;
 				inet_aton(v->value, &peer->mask);
 			} else if (!strcasecmp(v->name, "context")) {
-				if (ast_strlen_zero(peer->context))
-					ast_copy_string(peer->context, v->value, sizeof(peer->context));
+				ast_copy_string(peer->context, v->value, sizeof(peer->context));
 			} else if (!strcasecmp(v->name, "regexten")) {
 				ast_copy_string(peer->regexten, v->value, sizeof(peer->regexten));
 			} else if (!strcasecmp(v->name, "peercontext")) {
-				if (ast_strlen_zero(peer->peercontext))
-					ast_copy_string(peer->peercontext, v->value, sizeof(peer->peercontext));
+				ast_copy_string(peer->peercontext, v->value, sizeof(peer->peercontext));
 			} else if (!strcasecmp(v->name, "port")) {
 				if (ast_test_flag(peer, IAX_DYNAMIC))
 					peer->defaddr.sin_port = htons(atoi(v->value));



More information about the asterisk-commits mailing list