From ce5e5b0aa360b001778ff3c8ae21822002fa2c53 Mon Sep 17 00:00:00 2001 From: Nikita Popov Date: Wed, 10 Apr 2019 10:01:49 +0200 Subject: [PATCH] Use release for regex in imap The regex may be used as a cache key now. --- ext/imap/php_imap.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/ext/imap/php_imap.c b/ext/imap/php_imap.c index ca002e7fcd..3cee4e023e 100644 --- a/ext/imap/php_imap.c +++ b/ext/imap/php_imap.c @@ -1351,11 +1351,11 @@ PHP_FUNCTION(imap_append) /* Make sure the given internal_date string matches the RFC specifiedformat */ if ((pce = pcre_get_compiled_regex_cache(regex))== NULL) { - zend_string_free(regex); + zend_string_release(regex); RETURN_FALSE; } - zend_string_free(regex); + zend_string_release(regex); php_pcre_match_impl(pce, internal_date, return_value, subpats, global, 0, Z_L(0), Z_L(0)); -- 2.50.1