@@ -40,7 +40,7 @@ static ts_rsrc_id win32_globals_id;
40
40
static tsrm_win32_globals win32_globals ;
41
41
#endif
42
42
43
- static void tsrm_win32_ctor (tsrm_win32_globals * globals TSRMLS_DC )
43
+ static void tsrm_win32_ctor (tsrm_win32_globals * globals )
44
44
{
45
45
#ifdef ZTS
46
46
TSRMLS_CACHE_UPDATE ;
@@ -62,7 +62,7 @@ TSRMLS_CACHE_UPDATE;
62
62
globals -> impersonation_token_sid = NULL ;
63
63
}
64
64
65
- static void tsrm_win32_dtor (tsrm_win32_globals * globals TSRMLS_DC )
65
+ static void tsrm_win32_dtor (tsrm_win32_globals * globals )
66
66
{
67
67
shm_pair * ptr ;
68
68
@@ -95,18 +95,18 @@ TSRM_API void tsrm_win32_startup(void)
95
95
#ifdef ZTS
96
96
ts_allocate_id (& win32_globals_id , sizeof (tsrm_win32_globals ), (ts_allocate_ctor )tsrm_win32_ctor , (ts_allocate_ctor )tsrm_win32_dtor );
97
97
#else
98
- tsrm_win32_ctor (& win32_globals TSRMLS_CC );
98
+ tsrm_win32_ctor (& win32_globals );
99
99
#endif
100
100
}
101
101
102
102
TSRM_API void tsrm_win32_shutdown (void )
103
103
{
104
104
#ifndef ZTS
105
- tsrm_win32_dtor (& win32_globals TSRMLS_CC );
105
+ tsrm_win32_dtor (& win32_globals );
106
106
#endif
107
107
}
108
108
109
- char * tsrm_win32_get_path_sid_key (const char * pathname TSRMLS_DC )
109
+ char * tsrm_win32_get_path_sid_key (const char * pathname )
110
110
{
111
111
PSID pSid = TWG (impersonation_token_sid );
112
112
TCHAR * ptcSid = NULL ;
@@ -194,7 +194,7 @@ PSID tsrm_win32_get_token_sid(HANDLE hToken)
194
194
return NULL ;
195
195
}
196
196
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 )
198
198
{
199
199
time_t t ;
200
200
HANDLE thread_token = NULL ;
@@ -217,7 +217,7 @@ TSRM_API int tsrm_win32_access(const char *pathname, int mode TSRMLS_DC)
217
217
} else {
218
218
if (!IS_ABSOLUTE_PATH (pathname , strlen (pathname )+ 1 )) {
219
219
real_path = (char * )malloc (MAX_PATH );
220
- if (tsrm_realpath (pathname , real_path TSRMLS_CC ) == NULL ) {
220
+ if (tsrm_realpath (pathname , real_path ) == NULL ) {
221
221
goto Finished ;
222
222
}
223
223
pathname = real_path ;
@@ -281,14 +281,14 @@ TSRM_API int tsrm_win32_access(const char *pathname, int mode TSRMLS_DC)
281
281
282
282
if (CWDG (realpath_cache_size_limit )) {
283
283
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 );
285
285
if (bucket == NULL && real_path == NULL ) {
286
286
/* We used the pathname directly. Call tsrm_realpath */
287
287
/* so that entry is created in realpath cache */
288
288
real_path = (char * )malloc (MAX_PATH );
289
- if (tsrm_realpath (pathname , real_path TSRMLS_CC ) != NULL ) {
289
+ if (tsrm_realpath (pathname , real_path ) != NULL ) {
290
290
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 );
292
292
}
293
293
}
294
294
}
@@ -383,7 +383,7 @@ TSRM_API int tsrm_win32_access(const char *pathname, int mode TSRMLS_DC)
383
383
}
384
384
385
385
386
- static process_pair * process_get (FILE * stream TSRMLS_DC )
386
+ static process_pair * process_get (FILE * stream )
387
387
{
388
388
process_pair * ptr ;
389
389
process_pair * newptr ;
@@ -413,7 +413,6 @@ static shm_pair *shm_get(int key, void *addr)
413
413
{
414
414
shm_pair * ptr ;
415
415
shm_pair * newptr ;
416
- TSRMLS_FETCH ();
417
416
418
417
for (ptr = TWG (shm ); ptr < (TWG (shm ) + TWG (shm_size )); ptr ++ ) {
419
418
if (!ptr -> descriptor ) {
@@ -451,12 +450,11 @@ static HANDLE dupHandle(HANDLE fh, BOOL inherit) {
451
450
452
451
TSRM_API FILE * popen (const char * command , const char * type )
453
452
{
454
- TSRMLS_FETCH ();
455
453
456
- return popen_ex (command , type , NULL , NULL TSRMLS_CC );
454
+ return popen_ex (command , type , NULL , NULL );
457
455
}
458
456
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 )
460
458
{
461
459
FILE * stream = NULL ;
462
460
int fno , type_len , read , mode ;
@@ -553,7 +551,7 @@ TSRM_API FILE *popen_ex(const char *command, const char *type, const char *cwd,
553
551
}
554
552
555
553
CloseHandle (process .hThread );
556
- proc = process_get (NULL TSRMLS_CC );
554
+ proc = process_get (NULL );
557
555
558
556
if (read ) {
559
557
fno = _open_osfhandle ((tsrm_intptr_t )in , _O_RDONLY | mode );
@@ -573,9 +571,8 @@ TSRM_API int pclose(FILE *stream)
573
571
{
574
572
DWORD termstat = 0 ;
575
573
process_pair * process ;
576
- TSRMLS_FETCH ();
577
574
578
- if ((process = process_get (stream TSRMLS_CC )) == NULL ) {
575
+ if ((process = process_get (stream )) == NULL ) {
579
576
return 0 ;
580
577
}
581
578
0 commit comments