[asterisk-commits] file: trunk r74266 - in /trunk: ./ main/app.c

SVN commits to the Asterisk project asterisk-commits at lists.digium.com
Tue Jul 10 09:51:10 CDT 2007


Author: file
Date: Tue Jul 10 09:51:09 2007
New Revision: 74266

URL: http://svn.digium.com/view/asterisk?view=rev&rev=74266
Log:
Merged revisions 74265 via svnmerge from 
https://origsvn.digium.com/svn/asterisk/branches/1.4

................
r74265 | file | 2007-07-10 11:50:00 -0300 (Tue, 10 Jul 2007) | 10 lines

Merged revisions 74264 via svnmerge from 
https://origsvn.digium.com/svn/asterisk/branches/1.2

........
r74264 | file | 2007-07-10 11:48:00 -0300 (Tue, 10 Jul 2007) | 2 lines

Ensure the group information category exists before trying to do a string comparison with it. (issue #10171 reported by mlegas)

........

................

Modified:
    trunk/   (props changed)
    trunk/main/app.c

Propchange: trunk/
------------------------------------------------------------------------------
Binary property 'branch-1.4-merged' - no diff available.

Modified: trunk/main/app.c
URL: http://svn.digium.com/view/asterisk/trunk/main/app.c?view=diff&rev=74266&r1=74265&r2=74266
==============================================================================
--- trunk/main/app.c (original)
+++ trunk/main/app.c Tue Jul 10 09:51:09 2007
@@ -908,7 +908,7 @@
 	
 	AST_RWLIST_RDLOCK(&groups);
 	AST_RWLIST_TRAVERSE(&groups, gi, list) {
-		if (!strcasecmp(gi->group, group) && (ast_strlen_zero(category) || !strcasecmp(gi->category, category)))
+		if (!strcasecmp(gi->group, group) && (ast_strlen_zero(category) || (!ast_strlen_zero(gi->category) && !strcasecmp(gi->category, category))))
 			count++;
 	}
 	AST_RWLIST_UNLOCK(&groups);
@@ -931,7 +931,7 @@
 
 	AST_RWLIST_RDLOCK(&groups);
 	AST_RWLIST_TRAVERSE(&groups, gi, list) {
-		if (!regexec(&regexbuf, gi->group, 0, NULL, 0) && (ast_strlen_zero(category) || !strcasecmp(gi->category, category)))
+		if (!regexec(&regexbuf, gi->group, 0, NULL, 0) && (ast_strlen_zero(category) || (!ast_strlen_zero(gi->category) && !strcasecmp(gi->category, category))))
 			count++;
 	}
 	AST_RWLIST_UNLOCK(&groups);




More information about the asterisk-commits mailing list