summaryrefslogtreecommitdiff
path: root/ext/json/php_json.h
diff options
context:
space:
mode:
Diffstat (limited to 'ext/json/php_json.h')
-rw-r--r--ext/json/php_json.h5
1 files changed, 4 insertions, 1 deletions
diff --git a/ext/json/php_json.h b/ext/json/php_json.h
index 5b2dc127dd..64ad811bc7 100644
--- a/ext/json/php_json.h
+++ b/ext/json/php_json.h
@@ -44,7 +44,10 @@ ZEND_BEGIN_MODULE_GLOBALS(json)
ZEND_END_MODULE_GLOBALS(json)
#ifdef ZTS
-# define JSON_G(v) TSRMG(json_globals_id, zend_json_globals *, v)
+# define JSON_G(v) ZEND_TSRMG(json_globals_id, zend_json_globals *, v)
+# ifdef COMPILE_DL_JSON
+ZEND_TSRMLS_CACHE_EXTERN;
+# endif
#else
# define JSON_G(v) (json_globals.v)
#endif