summaryrefslogtreecommitdiff
path: root/ext/sqlite3/php_sqlite3.h
diff options
context:
space:
mode:
authorDmitry Stogov <dmitry@zend.com>2019-03-12 14:17:14 +0300
committerDmitry Stogov <dmitry@zend.com>2019-03-12 14:17:14 +0300
commit5f09db3073c670e7fc428076cbe7671c838830e2 (patch)
tree6ef3c536cc602c05e485cef8a8175ea8a59c0875 /ext/sqlite3/php_sqlite3.h
parentc56bd7e220dacd1bf65c08d6e1c4ab406b160993 (diff)
parentf1b306fe117cfbbe69ab4ef9713d39ea068e74c0 (diff)
downloadphp-git-5f09db3073c670e7fc428076cbe7671c838830e2.tar.gz
Merge branch 'PHP-7.4'
* PHP-7.4: Switch to use ZTS cache
Diffstat (limited to 'ext/sqlite3/php_sqlite3.h')
-rw-r--r--ext/sqlite3/php_sqlite3.h10
1 files changed, 4 insertions, 6 deletions
diff --git a/ext/sqlite3/php_sqlite3.h b/ext/sqlite3/php_sqlite3.h
index 411c4eb0ba..ca09e341ab 100644
--- a/ext/sqlite3/php_sqlite3.h
+++ b/ext/sqlite3/php_sqlite3.h
@@ -29,15 +29,13 @@ ZEND_BEGIN_MODULE_GLOBALS(sqlite3)
int dbconfig_defensive;
ZEND_END_MODULE_GLOBALS(sqlite3)
-#ifdef ZTS
-# define SQLITE3G(v) TSRMG(sqlite3_globals_id, zend_sqlite3_globals *, v)
-# ifdef COMPILE_DL_SQLITE3
+#if defined(ZTS) && defined(COMPILE_DL_SQLITE3)
ZEND_TSRMLS_CACHE_EXTERN()
-# endif
-#else
-# define SQLITE3G(v) (sqlite3_globals.v)
#endif
+ZEND_EXTERN_MODULE_GLOBALS(sqlite3)
+#define SQLITE3G(v) ZEND_MODULE_GLOBALS_ACCESSOR(sqlite3, v)
+
#define PHP_SQLITE3_ASSOC 1<<0
#define PHP_SQLITE3_NUM 1<<1
#define PHP_SQLITE3_BOTH (PHP_SQLITE3_ASSOC|PHP_SQLITE3_NUM)