[asterisk-commits] russell: branch 1.2 r52137 - /branches/1.2/apps/app_groupcount.c

asterisk-commits at lists.digium.com asterisk-commits at lists.digium.com
Wed Jan 24 17:39:51 MST 2007


Author: russell
Date: Wed Jan 24 18:39:50 2007
New Revision: 52137

URL: http://svn.digium.com/view/asterisk?view=rev&rev=52137
Log:
Fix a seg fault when running this application with no arguments from AGI.
(issue #8905, junky)

Modified:
    branches/1.2/apps/app_groupcount.c

Modified: branches/1.2/apps/app_groupcount.c
URL: http://svn.digium.com/view/asterisk/branches/1.2/apps/app_groupcount.c?view=diff&rev=52137&r1=52136&r2=52137
==============================================================================
--- branches/1.2/apps/app_groupcount.c (original)
+++ branches/1.2/apps/app_groupcount.c Wed Jan 24 18:39:50 2007
@@ -153,6 +153,11 @@
 	if (!deprecation_warning) {
 	        ast_log(LOG_WARNING, "The CheckGroup application has been deprecated, please use a combination of the GotoIf application and the GROUP_COUNT() function.\n");
 		deprecation_warning = 1;
+	}
+
+	if (ast_strlen_zero(data)) {
+		ast_log(LOG_WARNING, "CheckGroup requires an argument(max[@category][|options])\n");
+		return 0;
 	}
 
 	if (!(parse = ast_strdupa(data))) {



More information about the asterisk-commits mailing list