From d599d0cecde196d2063d6b6b56d4ffebbaeab238 Mon Sep 17 00:00:00 2001 From: Dmitry Stogov Date: Fri, 7 Mar 2014 17:14:16 +0400 Subject: [PATCH] Temporary fix memory leaks --- ext/pcre/php_pcre.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/ext/pcre/php_pcre.c b/ext/pcre/php_pcre.c index ce7b04cdf8..e15076072e 100644 --- a/ext/pcre/php_pcre.c +++ b/ext/pcre/php_pcre.c @@ -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); } /* }}} */ -- 2.40.0