summaryrefslogtreecommitdiff
path: root/ext/pdo_mysql/pdo_mysql.c
diff options
context:
space:
mode:
Diffstat (limited to 'ext/pdo_mysql/pdo_mysql.c')
-rw-r--r--ext/pdo_mysql/pdo_mysql.c6
1 files changed, 6 insertions, 0 deletions
diff --git a/ext/pdo_mysql/pdo_mysql.c b/ext/pdo_mysql/pdo_mysql.c
index 87ff61f6de..0e997b1dc7 100644
--- a/ext/pdo_mysql/pdo_mysql.c
+++ b/ext/pdo_mysql/pdo_mysql.c
@@ -32,6 +32,9 @@
#include "php_pdo_mysql_int.h"
#ifdef COMPILE_DL_PDO_MYSQL
+#ifdef ZTS
+ZEND_TSRMLS_CACHE_DEFINE;
+#endif
ZEND_GET_MODULE(pdo_mysql)
#endif
@@ -206,6 +209,9 @@ static PHP_RSHUTDOWN_FUNCTION(pdo_mysql)
*/
static PHP_GINIT_FUNCTION(pdo_mysql)
{
+#if defined(COMPILE_DL_PDO_MYSQL) && defined(ZTS)
+ZEND_TSRMLS_CACHE_UPDATE;
+#endif
#ifndef PHP_WIN32
pdo_mysql_globals->default_socket = NULL;
#endif