From: Reeze Xia Date: Sat, 28 Feb 2015 05:14:39 +0000 (+0800) Subject: Fixed memleak in alloc_globals_ctor X-Git-Tag: PRE_PHP7_EREG_MYSQL_REMOVALS~5^2 X-Git-Url: https://granicus.if.org/sourcecode?a=commitdiff_plain;h=85316b4bf02f75e6a89efb8b10416a0505a2ae4d;p=php Fixed memleak in alloc_globals_ctor This free operation is missed when new MM was introduced in master. --- diff --git a/Zend/zend_alloc.c b/Zend/zend_alloc.c index ad31d63454..70995688e8 100644 --- a/Zend/zend_alloc.c +++ b/Zend/zend_alloc.c @@ -1950,6 +1950,9 @@ void zend_mm_shutdown(zend_mm_heap *heap, int full, int silent) #if ZEND_MM_CUSTOM if (heap->use_custom_heap) { + if (full) { + free(heap); + } return; } #endif