]> granicus.if.org Git - php/commitdiff
this is the "right" ZTS-fix
authorThies C. Arntzen <thies@php.net>
Wed, 8 Dec 1999 11:47:50 +0000 (11:47 +0000)
committerThies C. Arntzen <thies@php.net>
Wed, 8 Dec 1999 11:47:50 +0000 (11:47 +0000)
ext/standard/assert.c

index 094f832c83cdfa7c8178e6a3d2fe03e471f9defc..f17a7220830111ff8f9d27416fa5860907842a9a 100644 (file)
@@ -88,12 +88,7 @@ PHP_INI_END()
 
 static void php_assert_init_globals(php_assert_globals *assert_globals)
 {
-       assert_globals->active = 0;
-       assert_globals->bail = 0;
-       assert_globals->warning = 1;
-       assert_globals->quiet_eval = 0;
-       assert_globals->default_callback = 0;
-       assert_globals->callback = 0;
+       ASSERT(callback) = 0;
 }
 
 PHP_MINIT_FUNCTION(assert)
@@ -102,6 +97,8 @@ PHP_MINIT_FUNCTION(assert)
 #ifdef ZTS
        ELS_FETCH();
        assert_globals_id = ts_allocate_id(sizeof(php_assert_globals), (ts_allocate_ctor) php_assert_init_globals, NULL);
+#else
+       ASSERT(callback) = 0;
 #endif
 
        REGISTER_INI_ENTRIES();