]> granicus.if.org Git - php/commitdiff
module_shutdown() calls ts_free_thread in ZTS mode. so SG() cannot be accessed
authorThies C. Arntzen <thies@php.net>
Sun, 5 Aug 2001 14:04:23 +0000 (14:04 +0000)
committerThies C. Arntzen <thies@php.net>
Sun, 5 Aug 2001 14:04:23 +0000 (14:04 +0000)
afterwards.

sapi/cgi/cgi_main.c

index b0d6134c7d76b72d59d27f983e5f20d51baa2f66..723ec6aee0cc29acdc5284f8a81479f3394e6c22 100644 (file)
@@ -769,7 +769,6 @@ any .htaccess restrictions anywhere on your site you can leave doc_root undefine
                }
 
                php_request_shutdown((void *) 0);
-               php_module_shutdown();
 
                if (SG(request_info).path_translated) {
                        free(SG(request_info).path_translated);
@@ -778,6 +777,8 @@ any .htaccess restrictions anywhere on your site you can leave doc_root undefine
                if (cgi_sapi_module.php_ini_path_override) {
                        free(cgi_sapi_module.php_ini_path_override);
                }
+
+               php_module_shutdown();
        } zend_catch {
                exit_status = -1;
        } zend_end_try();