From da2f58183377571fc7f10e5bdae1786f46fb9639 Mon Sep 17 00:00:00 2001 From: Anatol Belski Date: Thu, 21 Sep 2017 10:32:09 +0200 Subject: Fix thread safety --- main/main.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/main/main.c b/main/main.c index 6050d0db31..48c1a63c72 100644 --- a/main/main.c +++ b/main/main.c @@ -127,8 +127,8 @@ PHPAPI int core_globals_id; #define SAFE_FILENAME(f) ((f)?(f):"-") static char *get_safe_charset_hint(void) { - static char *lastHint = NULL; - static char *lastCodeset = NULL; + ZEND_TLS char *lastHint = NULL; + ZEND_TLS char *lastCodeset = NULL; char *hint = SG(default_charset); size_t len = strlen(hint); size_t i = 0; -- cgit v1.2.1