Skip to content

Commit bdeb220

Browse files
committedDec 13, 2014
first shot remove TSRMLS_* things
1 parent bb66f38 commit bdeb220

File tree

786 files changed

+27095
-27457
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

786 files changed

+27095
-27457
lines changed
 

‎TSRM/tsrm_win32.c

+15-18
Original file line numberDiff line numberDiff line change
@@ -40,7 +40,7 @@ static ts_rsrc_id win32_globals_id;
4040
static tsrm_win32_globals win32_globals;
4141
#endif
4242

43-
static void tsrm_win32_ctor(tsrm_win32_globals *globals TSRMLS_DC)
43+
static void tsrm_win32_ctor(tsrm_win32_globals *globals)
4444
{
4545
#ifdef ZTS
4646
TSRMLS_CACHE_UPDATE;
@@ -62,7 +62,7 @@ TSRMLS_CACHE_UPDATE;
6262
globals->impersonation_token_sid = NULL;
6363
}
6464

65-
static void tsrm_win32_dtor(tsrm_win32_globals *globals TSRMLS_DC)
65+
static void tsrm_win32_dtor(tsrm_win32_globals *globals)
6666
{
6767
shm_pair *ptr;
6868

@@ -95,18 +95,18 @@ TSRM_API void tsrm_win32_startup(void)
9595
#ifdef ZTS
9696
ts_allocate_id(&win32_globals_id, sizeof(tsrm_win32_globals), (ts_allocate_ctor)tsrm_win32_ctor, (ts_allocate_ctor)tsrm_win32_dtor);
9797
#else
98-
tsrm_win32_ctor(&win32_globals TSRMLS_CC);
98+
tsrm_win32_ctor(&win32_globals);
9999
#endif
100100
}
101101

102102
TSRM_API void tsrm_win32_shutdown(void)
103103
{
104104
#ifndef ZTS
105-
tsrm_win32_dtor(&win32_globals TSRMLS_CC);
105+
tsrm_win32_dtor(&win32_globals);
106106
#endif
107107
}
108108

109-
char * tsrm_win32_get_path_sid_key(const char *pathname TSRMLS_DC)
109+
char * tsrm_win32_get_path_sid_key(const char *pathname)
110110
{
111111
PSID pSid = TWG(impersonation_token_sid);
112112
TCHAR *ptcSid = NULL;
@@ -194,7 +194,7 @@ PSID tsrm_win32_get_token_sid(HANDLE hToken)
194194
return NULL;
195195
}
196196

197-
TSRM_API int tsrm_win32_access(const char *pathname, int mode TSRMLS_DC)
197+
TSRM_API int tsrm_win32_access(const char *pathname, int mode)
198198
{
199199
time_t t;
200200
HANDLE thread_token = NULL;
@@ -217,7 +217,7 @@ TSRM_API int tsrm_win32_access(const char *pathname, int mode TSRMLS_DC)
217217
} else {
218218
if(!IS_ABSOLUTE_PATH(pathname, strlen(pathname)+1)) {
219219
real_path = (char *)malloc(MAX_PATH);
220-
if(tsrm_realpath(pathname, real_path TSRMLS_CC) == NULL) {
220+
if(tsrm_realpath(pathname, real_path) == NULL) {
221221
goto Finished;
222222
}
223223
pathname = real_path;
@@ -281,14 +281,14 @@ TSRM_API int tsrm_win32_access(const char *pathname, int mode TSRMLS_DC)
281281

282282
if (CWDG(realpath_cache_size_limit)) {
283283
t = time(0);
284-
bucket = realpath_cache_lookup(pathname, (int)strlen(pathname), t TSRMLS_CC);
284+
bucket = realpath_cache_lookup(pathname, (int)strlen(pathname), t);
285285
if(bucket == NULL && real_path == NULL) {
286286
/* We used the pathname directly. Call tsrm_realpath */
287287
/* so that entry is created in realpath cache */
288288
real_path = (char *)malloc(MAX_PATH);
289-
if(tsrm_realpath(pathname, real_path TSRMLS_CC) != NULL) {
289+
if(tsrm_realpath(pathname, real_path) != NULL) {
290290
pathname = real_path;
291-
bucket = realpath_cache_lookup(pathname, (int)strlen(pathname), t TSRMLS_CC);
291+
bucket = realpath_cache_lookup(pathname, (int)strlen(pathname), t);
292292
}
293293
}
294294
}
@@ -383,7 +383,7 @@ TSRM_API int tsrm_win32_access(const char *pathname, int mode TSRMLS_DC)
383383
}
384384

385385

386-
static process_pair *process_get(FILE *stream TSRMLS_DC)
386+
static process_pair *process_get(FILE *stream)
387387
{
388388
process_pair *ptr;
389389
process_pair *newptr;
@@ -413,7 +413,6 @@ static shm_pair *shm_get(int key, void *addr)
413413
{
414414
shm_pair *ptr;
415415
shm_pair *newptr;
416-
TSRMLS_FETCH();
417416

418417
for (ptr = TWG(shm); ptr < (TWG(shm) + TWG(shm_size)); ptr++) {
419418
if (!ptr->descriptor) {
@@ -451,12 +450,11 @@ static HANDLE dupHandle(HANDLE fh, BOOL inherit) {
451450

452451
TSRM_API FILE *popen(const char *command, const char *type)
453452
{
454-
TSRMLS_FETCH();
455453

456-
return popen_ex(command, type, NULL, NULL TSRMLS_CC);
454+
return popen_ex(command, type, NULL, NULL);
457455
}
458456

459-
TSRM_API FILE *popen_ex(const char *command, const char *type, const char *cwd, char *env TSRMLS_DC)
457+
TSRM_API FILE *popen_ex(const char *command, const char *type, const char *cwd, char *env)
460458
{
461459
FILE *stream = NULL;
462460
int fno, type_len, read, mode;
@@ -553,7 +551,7 @@ TSRM_API FILE *popen_ex(const char *command, const char *type, const char *cwd,
553551
}
554552

555553
CloseHandle(process.hThread);
556-
proc = process_get(NULL TSRMLS_CC);
554+
proc = process_get(NULL);
557555

558556
if (read) {
559557
fno = _open_osfhandle((tsrm_intptr_t)in, _O_RDONLY | mode);
@@ -573,9 +571,8 @@ TSRM_API int pclose(FILE *stream)
573571
{
574572
DWORD termstat = 0;
575573
process_pair *process;
576-
TSRMLS_FETCH();
577574

578-
if ((process = process_get(stream TSRMLS_CC)) == NULL) {
575+
if ((process = process_get(stream)) == NULL) {
579576
return 0;
580577
}
581578

‎TSRM/tsrm_win32.h

+3-3
Original file line numberDiff line numberDiff line change
@@ -94,15 +94,15 @@ TSRMLS_CACHE_EXTERN;
9494
#define SHM_RND FILE_MAP_WRITE
9595
#define SHM_REMAP FILE_MAP_COPY
9696

97-
char * tsrm_win32_get_path_sid_key(const char *pathname TSRMLS_DC);
97+
char * tsrm_win32_get_path_sid_key(const char *pathname );
9898

9999
TSRM_API void tsrm_win32_startup(void);
100100
TSRM_API void tsrm_win32_shutdown(void);
101101

102-
TSRM_API FILE *popen_ex(const char *command, const char *type, const char *cwd, char *env TSRMLS_DC);
102+
TSRM_API FILE *popen_ex(const char *command, const char *type, const char *cwd, char *env);
103103
TSRM_API FILE *popen(const char *command, const char *type);
104104
TSRM_API int pclose(FILE *stream);
105-
TSRM_API int tsrm_win32_access(const char *pathname, int mode TSRMLS_DC);
105+
TSRM_API int tsrm_win32_access(const char *pathname, int mode);
106106
TSRM_API int win32_utime(const char *filename, struct utimbuf *buf);
107107

108108
TSRM_API int shmget(int key, int size, int flags);

0 commit comments

Comments
 (0)
Failed to load comments.