diff --git a/sapi/fpm/fpm/fpm_main.c b/sapi/fpm/fpm/fpm_main.c index 043e0e00a47c0..4b20e632dd361 100644 --- a/sapi/fpm/fpm/fpm_main.c +++ b/sapi/fpm/fpm/fpm_main.c @@ -1982,8 +1982,9 @@ consult the installation file that came with this distribution, or visit \n\ out: SG(server_context) = NULL; + php_module_shutdown(TSRMLS_C); + if (parent) { - php_module_shutdown(TSRMLS_C); sapi_shutdown(); }