]> granicus.if.org Git - php/commitdiff
leaks--
authorAntony Dovgal <tony2001@php.net>
Tue, 3 Oct 2006 21:37:02 +0000 (21:37 +0000)
committerAntony Dovgal <tony2001@php.net>
Tue, 3 Oct 2006 21:37:02 +0000 (21:37 +0000)
fix test

ext/pcre/php_pcre.c
ext/pcre/tests/bug26927.phpt

index 1ae9d55162db03f9be2a3372c260f8823abcfb3b..00bac77193bb3b55d6c49c23008199881589e77c 100644 (file)
@@ -1768,7 +1768,7 @@ PHP_FUNCTION(preg_quote)
        *q = '\0';
        
        /* Reallocate string and return it */
-       RETVAL_UTF8_STRINGL(erealloc(out_str, q - out_str + 1), q - out_str, 0);
+       RETVAL_UTF8_STRINGL(erealloc(out_str, q - out_str + 1), q - out_str, ZSTR_AUTOFREE);
 }
 /* }}} */
 
index 5c64deb37c574e4ab880942f7da2dfa012186283..7e74d3cddd66d0a8722966b456044cb59bd80ec4 100644 (file)
@@ -9,3 +9,6 @@ Bug #26927 (preg_quote() does not escape \0)
 --EXPECT--
 int(1)
 string(6) "a\000b"
+--UEXPECT--
+int(1)
+unicode(6) "a\000b"