[svn-commits] branch 1.2 r13925 - /branches/1.2/funcs/func_strings.c

svn-commits at lists.digium.com svn-commits at lists.digium.com
Tue Mar 21 10:45:57 MST 2006


Author: russell
Date: Tue Mar 21 11:45:56 2006
New Revision: 13925

URL: http://svn.digium.com/view/asterisk?rev=13925&view=rev
Log:
fix REGEX on strings that contain quotes (issue #6678)

Modified:
    branches/1.2/funcs/func_strings.c

Modified: branches/1.2/funcs/func_strings.c
URL: http://svn.digium.com/view/asterisk/branches/1.2/funcs/func_strings.c?rev=13925&r1=13924&r2=13925&view=diff
==============================================================================
--- branches/1.2/funcs/func_strings.c (original)
+++ branches/1.2/funcs/func_strings.c Tue Mar 21 11:45:56 2006
@@ -89,10 +89,9 @@
 	/* Regex in quotes */
 	arg = strchr(tmp, '"');
 	if (arg) {
-		arg++;
-		earg = strrchr(arg, '"');
+		earg = ++arg;
+		strsep(&earg, "\"");
 		if (earg) {
-			*earg++ = '\0';
 			/* Skip over any spaces before the data we are checking */
 			while (*earg == ' ')
 				earg++;



More information about the svn-commits mailing list