diff --git a/frankenphp.c b/frankenphp.c index 823ba11c1c..a47b6d80a7 100644 --- a/frankenphp.c +++ b/frankenphp.c @@ -1003,14 +1003,9 @@ PHP_FUNCTION(frankenphp_log) { } } -static void frankenphp_opcache_restart_hook(int reason) { - (void)reason; - go_schedule_opcache_reset(frankenphp_thread_index()); -} - /* {{{ thread-safe opcache reset */ PHP_FUNCTION(frankenphp_opcache_reset) { - frankenphp_opcache_restart_hook(0); + go_schedule_opcache_reset(frankenphp_thread_index()); RETVAL_TRUE; } /* }}} */ @@ -1705,13 +1700,6 @@ static void *php_main(void *arg) { frankenphp_sapi_module.startup(&frankenphp_sapi_module); -#if defined(ZTS) && PHP_VERSION_ID >= 80400 - /* Also restart everything on opcache memory overflow or similar events, the - * hook is triggered right before an opcache reset is scheduled - */ - zend_accel_schedule_restart_hook = frankenphp_opcache_restart_hook; -#endif - /* check if a default filter is set in php.ini and only filter if * it is, this is deprecated and will be removed in PHP 9 */ char *default_filter;