From: Xinchen Hui Date: Tue, 28 Apr 2015 03:14:21 +0000 (+0800) Subject: Fixed interned string leaks after new STATIC_KEY flag is introduced X-Git-Tag: PRE_PHP7_NSAPI_REMOVAL~141 X-Git-Url: https://granicus.if.org/sourcecode?a=commitdiff_plain;h=e5633865829a5160077e327445c7ff490f2d05d4;p=php Fixed interned string leaks after new STATIC_KEY flag is introduced --- diff --git a/Zend/zend_string.c b/Zend/zend_string.c index e8685a42b2..f395d5c36c 100644 --- a/Zend/zend_string.c +++ b/Zend/zend_string.c @@ -38,8 +38,7 @@ ZEND_API zend_ulong zend_hash_func(const char *str, size_t len) static void _str_dtor(zval *zv) { zend_string *str = Z_STR_P(zv); - GC_FLAGS(str) &= ~IS_STR_INTERNED; - GC_REFCOUNT(str) = 1; + pefree(str, GC_FLAGS(str) & IS_STR_PERSISTENT); } #endif