com php-src: vars with __declspec(thread) cannot us e __declspec(dllexport): TSRM/TSRM.c TSRM/TSR M.h

From: Date: Sat, 20 Sep 2014 20:13:10 +0000
Subject: com php-src: vars with __declspec(thread) cannot us e __declspec(dllexport): TSRM/TSRM.c TSRM/TSR M.h
Groups: php.cvs 
Request: Send a blank email to php-cvs+get-81820@lists.php.net to get a copy of this message
Commit: 27207436367eb10ec087ad47bfaf1b442bcf62b9 Author: Anatol Belski <ab@php.net> Sat, 20 Sep 2014 22:13:10 +0200 Parents: aa339d00d87b7476f4b2d8140ec58e9e94969a4b Branches: native-tls Link: http://git.php.net/?p=php-src.git;a=commitdiff;h=27207436367eb10ec087ad47bfaf1b442bcf62b9 Log: vars with __declspec(thread) cannot use __declspec(dllexport) Changed paths: M TSRM/TSRM.c M TSRM/TSRM.h Diff: diff --git a/TSRM/TSRM.c b/TSRM/TSRM.c index 32c2899...6b0bf44 100644 --- a/TSRM/TSRM.c +++ b/TSRM/TSRM.c @@ -63,8 +63,12 @@ static int tsrm_error_level; static FILE *tsrm_error_file; #ifdef USE___THREAD +#ifdef TSRM_WIN32 +TSRM_TLS void *tsrm_ls_cache = 0; +#else TSRM_API TSRM_TLS void *tsrm_ls_cache = 0; #endif +#endif #ifdef PASS_TSRMLS # define CALL_TSRMG_CTOR(ctor, globale, storage) (ctor)((globale), (storage)) diff --git a/TSRM/TSRM.h b/TSRM/TSRM.h index f77dcbf..840c303 100644 --- a/TSRM/TSRM.h +++ b/TSRM/TSRM.h @@ -109,7 +109,11 @@ extern "C" { # define TSRM_TLS __thread # endif +#ifdef TSRM_WIN32 +extern TSRM_TLS void *tsrm_ls_cache; +#else TSRM_API extern TSRM_TLS void *tsrm_ls_cache; +#endif #define TSRMG(id, type, element) \ ((type)((tsrm_uintptr_t)tsrm_ls_cache + id##_offset))->element

« previous php.cvs (#81820) next »