moriyoshi               Sun Nov 24 14:21:59 2002 EDT

  Modified files:              (Branch: PHP_4_3)
    /php4/ext/mbstring  mbstring.c 
  Log:
  Fixed mb_parse_str() bug pointed out by Yasuo.
  
  
Index: php4/ext/mbstring/mbstring.c
diff -u php4/ext/mbstring/mbstring.c:1.142.2.4 php4/ext/mbstring/mbstring.c:1.142.2.5
--- php4/ext/mbstring/mbstring.c:1.142.2.4      Thu Nov 21 11:21:33 2002
+++ php4/ext/mbstring/mbstring.c        Sun Nov 24 14:21:58 2002
@@ -17,7 +17,7 @@
    +----------------------------------------------------------------------+
  */
 
-/* $Id: mbstring.c,v 1.142.2.4 2002/11/21 16:21:33 hirokawa Exp $ */
+/* $Id: mbstring.c,v 1.142.2.5 2002/11/24 19:21:58 moriyoshi Exp $ */
 
 /*
  * PHP4 Multibyte String module "mbstring"
@@ -1691,8 +1691,11 @@
        var = encstr;
        n = Z_STRLEN_PP(arg_str);
        while (n > 0) {
-               if (*var == *separator) {
-                       num++;
+               char *p;
+               for (p = separator; *p != '\0'; ++p) {
+                       if (*p == *var) {
+                               num++;
+                       }
                }
                var++;
                n--;



-- 
PHP CVS Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php

Reply via email to