]> granicus.if.org Git - php/commitdiff
Temporary fix memory leaks
authorDmitry Stogov <dmitry@zend.com>
Fri, 7 Mar 2014 13:14:16 +0000 (17:14 +0400)
committerDmitry Stogov <dmitry@zend.com>
Fri, 7 Mar 2014 13:14:16 +0000 (17:14 +0400)
ext/pcre/php_pcre.c

index ce7b04cdf8dddb97b03ad6d09ec9e3a9c28a88dc..e15076072e8de61353dfe8da6768ad34734b14a7 100644 (file)
@@ -1718,7 +1718,8 @@ static PHP_FUNCTION(preg_quote)
        
        /* Reallocate string and return it */
 //???  RETVAL_STRINGL(erealloc(out_str, q - out_str + 1), q - out_str, 0);
-       RETVAL_STRINGL(erealloc(out_str, q - out_str + 1), q - out_str);
+       RETVAL_STRINGL(out_str, q - out_str);
+       efree(out_str);
 }
 /* }}} */