Skip to content

Commit 9ea60a8

Browse files
committed
In version 8.5, after forking the child process, the refresh_memory_manager() needs to be executed, otherwise it will crash
1 parent f877883 commit 9ea60a8

File tree

1 file changed

+3
-0
lines changed

1 file changed

+3
-0
lines changed

‎ext-src/php_swoole.cc‎

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1330,6 +1330,9 @@ bool sw_zval_is_serializable(const zval *struc) {
13301330
}
13311331

13321332
static void sw_after_fork(void *args) {
1333+
#if PHP_VERSION_ID >= 80500
1334+
refresh_memory_manager();
1335+
#endif
13331336
#ifdef ZEND_MAX_EXECUTION_TIMERS
13341337
zend_max_execution_timer_init();
13351338
#endif

0 commit comments

Comments
 (0)