derick          Thu Jun  2 04:31:08 2005 EDT

  Modified files:              (Branch: PHP_5_0)
    /php-src/ext/standard       string.c 
    /php-src    NEWS 
  Log:
  - MFH: Fixed memory corruption in stristr().
  
http://cvs.php.net/diff.php/php-src/ext/standard/string.c?r1=1.420.2.9&r2=1.420.2.10&ty=u
Index: php-src/ext/standard/string.c
diff -u php-src/ext/standard/string.c:1.420.2.9 
php-src/ext/standard/string.c:1.420.2.10
--- php-src/ext/standard/string.c:1.420.2.9     Tue May 31 08:55:33 2005
+++ php-src/ext/standard/string.c       Thu Jun  2 04:31:02 2005
@@ -18,7 +18,7 @@
    +----------------------------------------------------------------------+
  */
 
-/* $Id: string.c,v 1.420.2.9 2005/05/31 12:55:33 sniper Exp $ */
+/* $Id: string.c,v 1.420.2.10 2005/06/02 08:31:02 derick Exp $ */
 
 /* Synced with php 3.0 revision 1.193 1999-06-16 [ssb] */
 
@@ -1382,8 +1382,8 @@
                if (!Z_STRLEN_PP(needle)) {
                        php_error_docref(NULL TSRMLS_CC, E_WARNING, "Empty 
delimiter.");
                        efree(haystack_orig);
-                       zval_ptr_dtor(haystack);
-                       zval_ptr_dtor(needle);
+//                     zval_ptr_dtor(haystack);
+//                     zval_ptr_dtor(needle);
                        RETURN_FALSE;
                }
 
@@ -1409,8 +1409,8 @@
                RETVAL_FALSE;
        }
 
-       zval_ptr_dtor(haystack);
-       zval_ptr_dtor(needle);
+//     zval_ptr_dtor(haystack);
+//     zval_ptr_dtor(needle);
        efree(haystack_orig);
 }
 /* }}} */
http://cvs.php.net/diff.php/php-src/NEWS?r1=1.1760.2.411&r2=1.1760.2.412&ty=u
Index: php-src/NEWS
diff -u php-src/NEWS:1.1760.2.411 php-src/NEWS:1.1760.2.412
--- php-src/NEWS:1.1760.2.411   Wed Jun  1 18:28:37 2005
+++ php-src/NEWS        Thu Jun  2 04:31:03 2005
@@ -12,6 +12,7 @@
 - Fixed ext/mysqli to allocate less memory when fetching bound params
   of type (MEDIUM|LONG)BLOB/(MEDIUM|LONG)TEXT. (Andrey)
 - Fixed memory corruption in ImageTTFText() with 64bit systems. (Andrey)
+- Fixed memory corruption in stristr(). (Derick)
 - Fixed bug #33210 (relax jpeg recursive loop protection). (Ilia)
 - Fixed bug #33200 (preg_replace(): magic_quotes_sybase=On makes 'e' modifier
   misbehave). (Jani)

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

Reply via email to