[asterisk-commits] kmoore: branch 1.8 r372337 - /branches/1.8/main/pbx.c

SVN commits to the Asterisk project asterisk-commits at lists.digium.com
Wed Sep 5 13:29:04 CDT 2012


Author: kmoore
Date: Wed Sep  5 13:29:02 2012
New Revision: 372337

URL: http://svnview.digium.com/svn/asterisk?view=rev&rev=372337
Log:
Ensure counts generated in manager_show_dialplan_helper are correct

When manager_show_dialplan_helper was written, the counter increment
for the total number of contexts was placed with the extensions
increment instead of in the enclosing loop.  This function should
now generate correct context counts.

(closes issue AST-970)
Reported-by: John Bigelow

Modified:
    branches/1.8/main/pbx.c

Modified: branches/1.8/main/pbx.c
URL: http://svnview.digium.com/svn/asterisk/branches/1.8/main/pbx.c?view=diff&rev=372337&r1=372336&r2=372337
==============================================================================
--- branches/1.8/main/pbx.c (original)
+++ branches/1.8/main/pbx.c Wed Sep  5 13:29:02 2012
@@ -6752,6 +6752,7 @@
 			continue;	/* not the name we want */
 
 		dpc->context_existence = 1;
+		dpc->total_context++;
 
 		ast_debug(3, "manager_show_dialplan: Found Context: %s \n", ast_get_context_name(c));
 
@@ -6775,8 +6776,6 @@
 
 			dpc->extension_existence = 1;
 
-			/* may we print context info? */
-			dpc->total_context++;
 			dpc->total_exten++;
 
 			p = NULL;		/* walk next extension peers */




More information about the asterisk-commits mailing list