From: Nikita Popov Date: Wed, 10 Apr 2019 08:01:49 +0000 (+0200) Subject: Use release for regex in imap X-Git-Tag: php-7.4.0alpha1~569 X-Git-Url: https://granicus.if.org/sourcecode?a=commitdiff_plain;h=ce5e5b0aa360b001778ff3c8ae21822002fa2c53;p=php Use release for regex in imap The regex may be used as a cache key now. --- 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));