mirror of
https://github.com/php/php-src.git
synced 2025-08-15 21:48:51 +02:00
Merge branch 'PHP-8.0' into PHP-8.1
* PHP-8.0: Fix #81585: cached_chunks are not counted to real_size on shutdown
This commit is contained in:
commit
2362722dcf
2 changed files with 4 additions and 2 deletions
|
@ -2304,10 +2304,10 @@ void zend_mm_shutdown(zend_mm_heap *heap, bool full, bool silent)
|
|||
#endif
|
||||
memset(heap->free_slot, 0, sizeof(heap->free_slot));
|
||||
#if ZEND_MM_STAT || ZEND_MM_LIMIT
|
||||
heap->real_size = ZEND_MM_CHUNK_SIZE;
|
||||
heap->real_size = (heap->cached_chunks_count + 1) * ZEND_MM_CHUNK_SIZE;
|
||||
#endif
|
||||
#if ZEND_MM_STAT
|
||||
heap->real_peak = ZEND_MM_CHUNK_SIZE;
|
||||
heap->real_peak = (heap->cached_chunks_count + 1) * ZEND_MM_CHUNK_SIZE;
|
||||
#endif
|
||||
heap->chunks_count = 1;
|
||||
heap->peak_chunks_count = 1;
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue