diff options
-rw-r--r-- | Zend/zend.h | 5 | ||||
-rw-r--r-- | Zend/zend_constants.c | 6 | ||||
-rw-r--r-- | Zend/zend_extensions.h | 6 |
3 files changed, 11 insertions, 6 deletions
diff --git a/Zend/zend.h b/Zend/zend.h index 8b5b4e32ec..af437b37b9 100644 --- a/Zend/zend.h +++ b/Zend/zend.h @@ -123,6 +123,11 @@ #define ZEND_FILE_LINE_ORIG_RELAY_CC #endif /* ZEND_DEBUG */ +#ifdef ZTS +#define ZTS_V 1 +#else +#define ZTS_V 0 +#endif #include "zend_errors.h" #include "zend_alloc.h" diff --git a/Zend/zend_constants.c b/Zend/zend_constants.c index c09e271f8e..1f0395c6a8 100644 --- a/Zend/zend_constants.c +++ b/Zend/zend_constants.c @@ -134,6 +134,12 @@ void zend_register_standard_constants(ELS_D) c.value.type = IS_BOOL; zend_register_constant(&c ELS_CC); + c.name = zend_strndup(ZEND_STRL("ZEND_THREAD_SAFE")); + c.name_len = sizeof("ZEND_THREAD_SAFE"); + c.value.value.lval = ZTS_V; + c.value.type = IS_BOOL; + zend_register_constant(&c ELS_CC); + c.name = zend_strndup(ZEND_STRL("NULL")); c.name_len = sizeof("NULL"); c.value.type = IS_NULL; diff --git a/Zend/zend_extensions.h b/Zend/zend_extensions.h index a1abdadb8b..83b5bbc2ea 100644 --- a/Zend/zend_extensions.h +++ b/Zend/zend_extensions.h @@ -77,12 +77,6 @@ ZEND_API void zend_extension_dispatch_message(int message, void *arg); #define ZEND_EXTMSG_NEW_EXTENSION 1 -#ifdef ZTS -#define ZTS_V 1 -#else -#define ZTS_V 0 -#endif - #define ZEND_EXTENSION() \ ZEND_EXT_API zend_extension_version_info extension_version_info = { ZEND_EXTENSION_API_NO, ZEND_VERSION, ZTS_V, ZEND_DEBUG } |