From: Zeev Suraski Date: Thu, 30 Dec 1999 05:25:44 +0000 (+0000) Subject: This should enable people to use ALLOC_ZVAL() in code outside the php4.dll X-Git-Tag: PRE_ISSET_TYPE~1 X-Git-Url: https://granicus.if.org/sourcecode?a=commitdiff_plain;h=5864b57eeca950d78031ca6a3628a9d98e842d61;p=php This should enable people to use ALLOC_ZVAL() in code outside the php4.dll --- diff --git a/Zend/zend.c b/Zend/zend.c index 46967700ee..2aa5cbb0d1 100644 --- a/Zend/zend.c +++ b/Zend/zend.c @@ -52,7 +52,7 @@ ZEND_API int (*zend_get_ini_entry)(char *name, uint name_length, zval *contents) #ifdef ZTS ZEND_API int compiler_globals_id; ZEND_API int executor_globals_id; -int alloc_globals_id; +ZEND_API int alloc_globals_id; HashTable *global_function_table; HashTable *global_class_table; HashTable *global_constants_table; diff --git a/Zend/zend_alloc.c b/Zend/zend_alloc.c index 4fc580c73e..7b41548978 100644 --- a/Zend/zend_alloc.c +++ b/Zend/zend_alloc.c @@ -32,7 +32,7 @@ #endif #ifndef ZTS -zend_alloc_globals alloc_globals; +ZEND_API zend_alloc_globals alloc_globals; #endif diff --git a/Zend/zend_fast_cache.h b/Zend/zend_fast_cache.h index f487d360c5..660ec9df80 100644 --- a/Zend/zend_fast_cache.h +++ b/Zend/zend_fast_cache.h @@ -51,9 +51,6 @@ typedef struct _zend_fast_cache_list_entry { # define RECORD_ZVAL_CACHE_MISS(fc_type) #endif -#ifndef ZTS -extern zend_alloc_globals alloc_globals; -#endif #define ZEND_FAST_ALLOC(p, type, fc_type) \ { \ diff --git a/Zend/zend_globals.h b/Zend/zend_globals.h index 8ae06f263c..aecd3778c7 100644 --- a/Zend/zend_globals.h +++ b/Zend/zend_globals.h @@ -45,7 +45,7 @@ class ZendFlexLexer; BEGIN_EXTERN_C() ZEND_API extern int compiler_globals_id; ZEND_API extern int executor_globals_id; -extern int alloc_globals_id; +ZEND_API extern int alloc_globals_id; END_EXTERN_C() #endif diff --git a/Zend/zend_globals_macros.h b/Zend/zend_globals_macros.h index 75be8f27e2..02ef168e8f 100644 --- a/Zend/zend_globals_macros.h +++ b/Zend/zend_globals_macros.h @@ -82,6 +82,7 @@ extern ZEND_API zend_executor_globals executor_globals; # define ALS_CC # define AG(v) (alloc_globals.v) # define ALS_FETCH() +extern ZEND_API zend_alloc_globals alloc_globals; #endif #endif /* _ZEND_GLOBALS_MACROS_H */