From: Dmitry Stogov Date: Fri, 28 Jun 2019 07:43:56 +0000 (+0300) Subject: Fixed use-after-free X-Git-Tag: php-7.4.0alpha3~147 X-Git-Url: https://granicus.if.org/sourcecode?a=commitdiff_plain;h=ba8033feb0c2e8c6665a55d13ae2d0957ce72add;p=php Fixed use-after-free --- diff --git a/Zend/zend_execute_API.c b/Zend/zend_execute_API.c index 4117b48baf..7606351a0f 100644 --- a/Zend/zend_execute_API.c +++ b/Zend/zend_execute_API.c @@ -359,6 +359,7 @@ void shutdown_executor(void) /* {{{ */ if (ht) { ZEND_ASSERT(GC_REFCOUNT(ht) == 1); zend_array_destroy(ht); + ZEND_MAP_PTR_SET(op_array->static_variables_ptr, NULL); } } } ZEND_HASH_FOREACH_END(); @@ -390,6 +391,7 @@ void shutdown_executor(void) /* {{{ */ if (ht) { ZEND_ASSERT(GC_REFCOUNT(ht) == 1); zend_array_destroy(ht); + ZEND_MAP_PTR_SET(op_array->static_variables_ptr, NULL); } } }