summaryrefslogtreecommitdiff
path: root/sapi/cli/php_cli.c
diff options
context:
space:
mode:
Diffstat (limited to 'sapi/cli/php_cli.c')
-rw-r--r--sapi/cli/php_cli.c5
1 files changed, 5 insertions, 0 deletions
diff --git a/sapi/cli/php_cli.c b/sapi/cli/php_cli.c
index ef45ef6ef9..f1dab46086 100644
--- a/sapi/cli/php_cli.c
+++ b/sapi/cli/php_cli.c
@@ -99,6 +99,10 @@ PHPAPI extern char *php_ini_opened_path;
PHPAPI extern char *php_ini_scanned_path;
PHPAPI extern char *php_ini_scanned_files;
+#ifdef ZTS
+ZEND_TSRMLS_CACHE_DEFINE;
+#endif
+
#ifndef O_BINARY
#define O_BINARY 0
#endif
@@ -1236,6 +1240,7 @@ int main(int argc, char *argv[])
#ifdef ZTS
tsrm_startup(1, 1, 0, NULL);
tsrm_ls = ts_resource(0);
+ ZEND_TSRMLS_CACHE_UPDATE;
#endif
#ifdef PHP_WIN32