cvs: php4 /ext/session session.c /ext/standard url_scanner_ex.c url_scanner_ex.h url_scanner_ex.re /sapi/apache php_apache.c
| From: | Sascha Schumann | Date: | Sun, 05 Aug 2001 16:43:58 +0000 |
| Subject: | cvs: php4 /ext/session session.c /ext/standard url_scanner_ex.c url_scanner_ex.h url_scanner_ex.re /sapi/apache php_apache.c | ||
| Groups: | php.cvs | ||
| Request: | Send a blank email to php-cvs+get-6579@lists.php.net to get a copy of this message | ||
sas Sun Aug 5 12:43:58 2001 EDT
Modified files:
/php4/ext/session session.c
/php4/ext/standard url_scanner_ex.c url_scanner_ex.h
url_scanner_ex.re
/php4/sapi/apache php_apache.c
Log:
more tsrm cleanup
Index: php4/ext/session/session.c diff -u php4/ext/session/session.c:1.231 php4/ext/session/session.c:1.232 --- php4/ext/session/session.c:1.231 Sun Aug 5 11:29:38 2001 +++ php4/ext/session/session.c Sun Aug 5 12:43:57 2001 @@ -17,7 +17,7 @@ +----------------------------------------------------------------------+ */ -/* $Id: session.c,v 1.231 2001/08/05 15:29:38 sas Exp $ */ +/* $Id: session.c,v 1.232 2001/08/05 16:43:57 sas Exp $ */ #ifdef HAVE_CONFIG_H #include "config.h" @@ -1271,13 +1271,13 @@ void session_adapt_uris(const char *src, size_t srclen, char **new, size_t *newlen TSRMLS_DC) { if (PS(define_sid) && (PS(session_status) == php_session_active)) - *new = url_adapt_ext_ex(src, srclen, PS(session_name), PS(id), newlen); + *new = url_adapt_ext_ex(src, srclen, PS(session_name), PS(id), newlen TSRMLS_CC); } void session_adapt_url(const char *url, size_t urllen, char **new, size_t *newlen TSRMLS_DC) { if (PS(define_sid) && (PS(session_status) == php_session_active)) - *new = url_adapt_single_url(url, urllen, PS(session_name), PS(id), newlen); + *new = url_adapt_single_url(url, urllen, PS(session_name), PS(id), newlen TSRMLS_CC); } void session_adapt_flush(int (*write)(const char *, uint TSRMLS_DC) TSRMLS_DC) @@ -1285,7 +1285,7 @@ char *str; size_t len; - str = url_adapt_flush(&len); + str = url_adapt_flush(&len TSRMLS_CC); if (str) write(str, len TSRMLS_CC); } Index: php4/ext/standard/url_scanner_ex.c diff -u php4/ext/standard/url_scanner_ex.c:1.36 php4/ext/standard/url_scanner_ex.c:1.37 --- php4/ext/standard/url_scanner_ex.c:1.36 Tue Jul 31 03:09:45 2001 +++ php4/ext/standard/url_scanner_ex.c Sun Aug 5 12:43:57 2001 @@ -1,5 +1,5 @@ -/* Generated by re2c 0.5 on Wed Jul 4 17:05:51 2001 */ -#line 1 "/home/sas/src/php4/ext/standard/url_scanner_ex.re" +/* Generated by re2c 0.5 on Sun Aug 5 18:41:23 2001 */ +#line 1 "url_scanner_ex.re" /* +----------------------------------------------------------------------+ | PHP version 4.0 | @@ -88,7 +88,7 @@ STD_PHP_INI_ENTRY("url_rewriter.tags", "a=href,area=href,frame=src,form=fakeentry", PHP_INI_ALL, OnUpdateTags, url_adapt_state_ex, php_basic_globals, basic_globals) PHP_INI_END() -#line 94 +#line 93 #define YYFILL(n) goto done @@ -153,25 +153,25 @@ if(yych >= ';') goto yy4; yy2: yych = *++YYCURSOR; yy3: -#line 112 +#line 111 { smart_str_append(dest, url); return; } yy4: yych = *++YYCURSOR; yy5: -#line 113 +#line 112 { sep = separator; goto done; } yy6: yych = *++YYCURSOR; yy7: -#line 114 +#line 113 { bash = p; goto done; } yy8: ++YYCURSOR; if(YYLIMIT == YYCURSOR) YYFILL(1); yych = *YYCURSOR; yy9: if(yybm[0+yych] & 128) goto yy8; yy10: -#line 115 +#line 114 { goto scan; } } -#line 116 +#line 115 done: @@ -291,13 +291,12 @@ #define scdebug(x) #endif -static inline void mainloop(url_adapt_state_ex_t *ctx, const char *newdata, size_t newlen) +static inline void mainloop(url_adapt_state_ex_t *ctx, const char *newdata, size_t newlen TSRMLS_DC) { char *end, *q; char *xp; char *start; int rest; - TSRMLS_FETCH(); smart_str_appendl(&ctx->buf, newdata, newlen); @@ -364,17 +363,17 @@ if(yybm[0+yych] & 128) goto yy15; yy13: yych = *++YYCURSOR; yy14: -#line 264 +#line 262 { passthru(STD_ARGS); STATE = STATE_TAG; goto state_tag; } yy15: ++YYCURSOR; if(YYLIMIT == YYCURSOR) YYFILL(1); yych = *YYCURSOR; yy16: if(yybm[0+yych] & 128) goto yy15; yy17: -#line 265 +#line 263 { passthru(STD_ARGS); goto state_plain; } } -#line 266 +#line 264 state_tag: @@ -428,11 +427,11 @@ yy20: yych = *++YYCURSOR; goto yy25; yy21: -#line 271 +#line 269 { handle_tag(STD_ARGS); /* Sets STATE */; passthru(STD_ARGS); if (STATE == STATE_PLAIN) goto state_plain; else goto state_next_arg; } yy22: yych = *++YYCURSOR; yy23: -#line 272 +#line 270 { passthru(STD_ARGS); goto state_plain_begin; } yy24: ++YYCURSOR; if(YYLIMIT == YYCURSOR) YYFILL(1); @@ -440,7 +439,7 @@ yy25: if(yybm[0+yych] & 128) goto yy24; goto yy21; } -#line 273 +#line 271 state_next_arg_begin: @@ -511,20 +510,20 @@ } yy28: yych = *++YYCURSOR; yy29: -#line 281 +#line 279 { passthru(STD_ARGS); handle_form(STD_ARGS); goto state_plain_begin; } yy30: yych = *++YYCURSOR; goto yy37; yy31: -#line 282 +#line 280 { passthru(STD_ARGS); goto state_next_arg; } yy32: yych = *++YYCURSOR; yy33: -#line 283 +#line 281 { --YYCURSOR; STATE = STATE_ARG; goto state_arg; } yy34: yych = *++YYCURSOR; yy35: -#line 284 +#line 282 { passthru(STD_ARGS); goto state_plain_begin; } yy36: ++YYCURSOR; if(YYLIMIT == YYCURSOR) YYFILL(1); @@ -532,7 +531,7 @@ yy37: if(yybm[0+yych] & 128) goto yy36; goto yy31; } -#line 285 +#line 283 state_arg: @@ -586,11 +585,11 @@ yy40: yych = *++YYCURSOR; goto yy45; yy41: -#line 290 +#line 288 { passthru(STD_ARGS); handle_arg(STD_ARGS); STATE = STATE_BEFORE_VAL; goto state_before_val; } yy42: yych = *++YYCURSOR; yy43: -#line 291 +#line 289 { passthru(STD_ARGS); STATE = STATE_NEXT_ARG; goto state_next_arg; } yy44: ++YYCURSOR; if(YYLIMIT == YYCURSOR) YYFILL(1); @@ -598,7 +597,7 @@ yy45: if(yybm[0+yych] & 128) goto yy44; goto yy41; } -#line 292 +#line 290 state_before_val: @@ -653,12 +652,12 @@ if(yych == ' ') goto yy55; if(yych == '=') goto yy53; yy49: -#line 298 +#line 296 { --YYCURSOR; goto state_next_arg_begin; } yy50: yych = *++YYCURSOR; goto yy54; yy51: -#line 297 +#line 295 { passthru(STD_ARGS); STATE = STATE_VAL; goto state_val; } yy52: yych = *++YYCURSOR; goto yy49; @@ -677,7 +676,7 @@ case 0: goto yy49; } } -#line 299 +#line 297 @@ -747,7 +746,7 @@ yych = *(YYMARKER = ++YYCURSOR); if(yych != '>') goto yy74; yy61: -#line 308 +#line 306 { passthru(STD_ARGS); goto state_next_arg_begin; } yy62: yyaccept = 0; yych = *(YYMARKER = ++YYCURSOR); @@ -756,7 +755,7 @@ yy63: yych = *++YYCURSOR; goto yy67; yy64: -#line 307 +#line 305 { handle_val(STD_ARGS, 0, '"'); goto state_next_arg_begin; } yy65: yych = *++YYCURSOR; goto yy61; @@ -776,7 +775,7 @@ } yy71: yych = *++YYCURSOR; yy72: -#line 306 +#line 304 { handle_val(STD_ARGS, 1, '\''); goto state_next_arg_begin; } yy73: ++YYCURSOR; if(YYLIMIT == YYCURSOR) YYFILL(1); @@ -785,10 +784,10 @@ if(yych >= '>') goto yy70; yy75: yych = *++YYCURSOR; yy76: -#line 305 +#line 303 { handle_val(STD_ARGS, 1, '"'); goto state_next_arg_begin; } } -#line 309 +#line 307 stop: @@ -801,11 +800,10 @@ ctx->buf.len = rest; } -char *url_adapt_flush(size_t *newlen) +char *url_adapt_flush(size_t *newlen TSRMLS_DC) { char *ret = NULL; url_adapt_state_ex_t *ctx; - TSRMLS_FETCH(); ctx = &BG(url_adapt_state_ex); @@ -819,13 +817,12 @@ return ret; } -char *url_adapt_single_url(const char *url, size_t urllen, const char *name, const char *value, size_t *newlen) +char *url_adapt_single_url(const char *url, size_t urllen, const char *name, const char *value, size_t *newlen TSRMLS_DC) { smart_str surl = {0}; smart_str buf = {0}; smart_str sname = {0}; smart_str sval = {0}; - TSRMLS_FETCH(); smart_str_setl(&surl, url, urllen); smart_str_sets(&sname, name); @@ -839,17 +836,16 @@ return buf.c; } -char *url_adapt_ext(const char *src, size_t srclen, const char *name, const char *value, size_t *newlen) +char *url_adapt_ext(const char *src, size_t srclen, const char *name, const char *value, size_t *newlen TSRMLS_DC) { char *ret; url_adapt_state_ex_t *ctx; - TSRMLS_FETCH(); ctx = &BG(url_adapt_state_ex); smart_str_sets(&ctx->q_name, name); smart_str_sets(&ctx->q_value, value); - mainloop(ctx, src, srclen); + mainloop(ctx, src, srclen TSRMLS_CC); *newlen = ctx->result.len; if (!ctx->result.c) @@ -889,7 +885,9 @@ url_adapt_state_ex_t *ctx; ctx = &BG(url_adapt_state_ex); - ctx->tags = NULL; + + ctx->tags = NULL; + REGISTER_INI_ENTRIES(); return SUCCESS; } Index: php4/ext/standard/url_scanner_ex.h diff -u php4/ext/standard/url_scanner_ex.h:1.11 php4/ext/standard/url_scanner_ex.h:1.12 --- php4/ext/standard/url_scanner_ex.h:1.11 Wed Jul 4 11:30:21 2001 +++ php4/ext/standard/url_scanner_ex.h Sun Aug 5 12:43:57 2001 @@ -24,11 +24,11 @@ PHP_RSHUTDOWN_FUNCTION(url_scanner_ex); PHP_RINIT_FUNCTION(url_scanner_ex); -char *url_adapt_ext_ex(const char *src, size_t srclen, const char *name, const char *value, size_t *newlen); +char *url_adapt_ext_ex(const char *src, size_t srclen, const char *name, const char *value, size_t *newlen TSRMLS_DC); -char *url_adapt_single_url(const char *url, size_t urllen, const char *name, const char *value, size_t *newlen); +char *url_adapt_single_url(const char *url, size_t urllen, const char *name, const char *value, size_t *newlen TSRMLS_DC); -char *url_adapt_flush(size_t *); +char *url_adapt_flush(size_t * TSRMLS_DC); #include "php_smart_str_public.h" Index: php4/ext/standard/url_scanner_ex.re diff -u php4/ext/standard/url_scanner_ex.re:1.33 php4/ext/standard/url_scanner_ex.re:1.34 --- php4/ext/standard/url_scanner_ex.re:1.33 Sat Jul 28 07:36:19 2001 +++ php4/ext/standard/url_scanner_ex.re Sun Aug 5 12:43:57 2001 @@ -45,7 +45,6 @@ char *key; char *lasts; char *tmp; - TSRMLS_FETCH(); ctx = &BG(url_adapt_state_ex); @@ -232,13 +231,12 @@ #define scdebug(x) #endif -static inline void mainloop(url_adapt_state_ex_t *ctx, const char *newdata, size_t newlen) +static inline void mainloop(url_adapt_state_ex_t *ctx, const char *newdata, size_t newlen TSRMLS_DC) { char *end, *q; char *xp; char *start; int rest; - TSRMLS_FETCH(); smart_str_appendl(&ctx->buf, newdata, newlen); @@ -318,11 +316,10 @@ ctx->buf.len = rest; } -char *url_adapt_flush(size_t *newlen) +char *url_adapt_flush(size_t *newlen TSRMLS_DC) { char *ret = NULL; url_adapt_state_ex_t *ctx; - TSRMLS_FETCH(); ctx = &BG(url_adapt_state_ex); @@ -336,13 +333,12 @@ return ret; } -char *url_adapt_single_url(const char *url, size_t urllen, const char *name, const char *value, size_t *newlen) +char *url_adapt_single_url(const char *url, size_t urllen, const char *name, const char *value, size_t *newlen TSRMLS_DC) { smart_str surl = {0}; smart_str buf = {0}; smart_str sname = {0}; smart_str sval = {0}; - TSRMLS_FETCH(); smart_str_setl(&surl, url, urllen); smart_str_sets(&sname, name); @@ -356,17 +352,16 @@ return buf.c; } -char *url_adapt_ext(const char *src, size_t srclen, const char *name, const char *value, size_t *newlen) +char *url_adapt_ext(const char *src, size_t srclen, const char *name, const char *value, size_t *newlen TSRMLS_DC) { char *ret; url_adapt_state_ex_t *ctx; - TSRMLS_FETCH(); ctx = &BG(url_adapt_state_ex); smart_str_sets(&ctx->q_name, name); smart_str_sets(&ctx->q_value, value); - mainloop(ctx, src, srclen); + mainloop(ctx, src, srclen TSRMLS_CC); *newlen = ctx->result.len; if (!ctx->result.c) @@ -379,7 +374,6 @@ PHP_RINIT_FUNCTION(url_scanner) { url_adapt_state_ex_t *ctx; - TSRMLS_FETCH(); ctx = &BG(url_adapt_state_ex); @@ -391,7 +385,6 @@ PHP_RSHUTDOWN_FUNCTION(url_scanner) { url_adapt_state_ex_t *ctx; - TSRMLS_FETCH(); ctx = &BG(url_adapt_state_ex); @@ -406,7 +399,6 @@ PHP_MINIT_FUNCTION(url_scanner) { url_adapt_state_ex_t *ctx; - TSRMLS_FETCH(); ctx = &BG(url_adapt_state_ex); @@ -418,8 +410,6 @@ PHP_MSHUTDOWN_FUNCTION(url_scanner) { - TSRMLS_FETCH(); - UNREGISTER_INI_ENTRIES(); zend_hash_destroy(BG(url_adapt_state_ex).tags); free(BG(url_adapt_state_ex).tags); Index: php4/sapi/apache/php_apache.c diff -u php4/sapi/apache/php_apache.c:1.43 php4/sapi/apache/php_apache.c:1.44 --- php4/sapi/apache/php_apache.c:1.43 Sun Aug 5 11:55:43 2001 +++ php4/sapi/apache/php_apache.c Sun Aug 5 12:43:57 2001 @@ -17,7 +17,7 @@ | David Sklar <sklar@student.net> | +----------------------------------------------------------------------+ */ -/* $Id: php_apache.c,v 1.43 2001/08/05 15:55:43 sas Exp $ */ +/* $Id: php_apache.c,v 1.44 2001/08/05 16:43:57 sas Exp $ */ #define NO_REGEX_EXTRA_H @@ -182,7 +182,6 @@ extern char *user_name; extern gid_t group_id; extern int max_requests_per_child; - TSRMLS_FETCH(); serv = ((request_rec *) SG(server_context))->server;
Index: php4/ext/session/session.c diff -u php4/ext/session/session.c:1.231 php4/ext/session/session.c:1.232 --- php4/ext/session/session.c:1.231 Sun Aug 5 11:29:38 2001 +++ php4/ext/session/session.c Sun Aug 5 12:43:57 2001 @@ -17,7 +17,7 @@ +----------------------------------------------------------------------+ */ -/* $Id: session.c,v 1.231 2001/08/05 15:29:38 sas Exp $ */ +/* $Id: session.c,v 1.232 2001/08/05 16:43:57 sas Exp $ */ #ifdef HAVE_CONFIG_H #include "config.h" @@ -1271,13 +1271,13 @@ void session_adapt_uris(const char *src, size_t srclen, char **new, size_t *newlen TSRMLS_DC) { if (PS(define_sid) && (PS(session_status) == php_session_active)) - *new = url_adapt_ext_ex(src, srclen, PS(session_name), PS(id), newlen); + *new = url_adapt_ext_ex(src, srclen, PS(session_name), PS(id), newlen TSRMLS_CC); } void session_adapt_url(const char *url, size_t urllen, char **new, size_t *newlen TSRMLS_DC) { if (PS(define_sid) && (PS(session_status) == php_session_active)) - *new = url_adapt_single_url(url, urllen, PS(session_name), PS(id), newlen); + *new = url_adapt_single_url(url, urllen, PS(session_name), PS(id), newlen TSRMLS_CC); } void session_adapt_flush(int (*write)(const char *, uint TSRMLS_DC) TSRMLS_DC) @@ -1285,7 +1285,7 @@ char *str; size_t len; - str = url_adapt_flush(&len); + str = url_adapt_flush(&len TSRMLS_CC); if (str) write(str, len TSRMLS_CC); } Index: php4/ext/standard/url_scanner_ex.c diff -u php4/ext/standard/url_scanner_ex.c:1.36 php4/ext/standard/url_scanner_ex.c:1.37 --- php4/ext/standard/url_scanner_ex.c:1.36 Tue Jul 31 03:09:45 2001 +++ php4/ext/standard/url_scanner_ex.c Sun Aug 5 12:43:57 2001 @@ -1,5 +1,5 @@ -/* Generated by re2c 0.5 on Wed Jul 4 17:05:51 2001 */ -#line 1 "/home/sas/src/php4/ext/standard/url_scanner_ex.re" +/* Generated by re2c 0.5 on Sun Aug 5 18:41:23 2001 */ +#line 1 "url_scanner_ex.re" /* +----------------------------------------------------------------------+ | PHP version 4.0 | @@ -88,7 +88,7 @@ STD_PHP_INI_ENTRY("url_rewriter.tags", "a=href,area=href,frame=src,form=fakeentry", PHP_INI_ALL, OnUpdateTags, url_adapt_state_ex, php_basic_globals, basic_globals) PHP_INI_END() -#line 94 +#line 93 #define YYFILL(n) goto done @@ -153,25 +153,25 @@ if(yych >= ';') goto yy4; yy2: yych = *++YYCURSOR; yy3: -#line 112 +#line 111 { smart_str_append(dest, url); return; } yy4: yych = *++YYCURSOR; yy5: -#line 113 +#line 112 { sep = separator; goto done; } yy6: yych = *++YYCURSOR; yy7: -#line 114 +#line 113 { bash = p; goto done; } yy8: ++YYCURSOR; if(YYLIMIT == YYCURSOR) YYFILL(1); yych = *YYCURSOR; yy9: if(yybm[0+yych] & 128) goto yy8; yy10: -#line 115 +#line 114 { goto scan; } } -#line 116 +#line 115 done: @@ -291,13 +291,12 @@ #define scdebug(x) #endif -static inline void mainloop(url_adapt_state_ex_t *ctx, const char *newdata, size_t newlen) +static inline void mainloop(url_adapt_state_ex_t *ctx, const char *newdata, size_t newlen TSRMLS_DC) { char *end, *q; char *xp; char *start; int rest; - TSRMLS_FETCH(); smart_str_appendl(&ctx->buf, newdata, newlen); @@ -364,17 +363,17 @@ if(yybm[0+yych] & 128) goto yy15; yy13: yych = *++YYCURSOR; yy14: -#line 264 +#line 262 { passthru(STD_ARGS); STATE = STATE_TAG; goto state_tag; } yy15: ++YYCURSOR; if(YYLIMIT == YYCURSOR) YYFILL(1); yych = *YYCURSOR; yy16: if(yybm[0+yych] & 128) goto yy15; yy17: -#line 265 +#line 263 { passthru(STD_ARGS); goto state_plain; } } -#line 266 +#line 264 state_tag: @@ -428,11 +427,11 @@ yy20: yych = *++YYCURSOR; goto yy25; yy21: -#line 271 +#line 269 { handle_tag(STD_ARGS); /* Sets STATE */; passthru(STD_ARGS); if (STATE == STATE_PLAIN) goto state_plain; else goto state_next_arg; } yy22: yych = *++YYCURSOR; yy23: -#line 272 +#line 270 { passthru(STD_ARGS); goto state_plain_begin; } yy24: ++YYCURSOR; if(YYLIMIT == YYCURSOR) YYFILL(1); @@ -440,7 +439,7 @@ yy25: if(yybm[0+yych] & 128) goto yy24; goto yy21; } -#line 273 +#line 271 state_next_arg_begin: @@ -511,20 +510,20 @@ } yy28: yych = *++YYCURSOR; yy29: -#line 281 +#line 279 { passthru(STD_ARGS); handle_form(STD_ARGS); goto state_plain_begin; } yy30: yych = *++YYCURSOR; goto yy37; yy31: -#line 282 +#line 280 { passthru(STD_ARGS); goto state_next_arg; } yy32: yych = *++YYCURSOR; yy33: -#line 283 +#line 281 { --YYCURSOR; STATE = STATE_ARG; goto state_arg; } yy34: yych = *++YYCURSOR; yy35: -#line 284 +#line 282 { passthru(STD_ARGS); goto state_plain_begin; } yy36: ++YYCURSOR; if(YYLIMIT == YYCURSOR) YYFILL(1); @@ -532,7 +531,7 @@ yy37: if(yybm[0+yych] & 128) goto yy36; goto yy31; } -#line 285 +#line 283 state_arg: @@ -586,11 +585,11 @@ yy40: yych = *++YYCURSOR; goto yy45; yy41: -#line 290 +#line 288 { passthru(STD_ARGS); handle_arg(STD_ARGS); STATE = STATE_BEFORE_VAL; goto state_before_val; } yy42: yych = *++YYCURSOR; yy43: -#line 291 +#line 289 { passthru(STD_ARGS); STATE = STATE_NEXT_ARG; goto state_next_arg; } yy44: ++YYCURSOR; if(YYLIMIT == YYCURSOR) YYFILL(1); @@ -598,7 +597,7 @@ yy45: if(yybm[0+yych] & 128) goto yy44; goto yy41; } -#line 292 +#line 290 state_before_val: @@ -653,12 +652,12 @@ if(yych == ' ') goto yy55; if(yych == '=') goto yy53; yy49: -#line 298 +#line 296 { --YYCURSOR; goto state_next_arg_begin; } yy50: yych = *++YYCURSOR; goto yy54; yy51: -#line 297 +#line 295 { passthru(STD_ARGS); STATE = STATE_VAL; goto state_val; } yy52: yych = *++YYCURSOR; goto yy49; @@ -677,7 +676,7 @@ case 0: goto yy49; } } -#line 299 +#line 297 @@ -747,7 +746,7 @@ yych = *(YYMARKER = ++YYCURSOR); if(yych != '>') goto yy74; yy61: -#line 308 +#line 306 { passthru(STD_ARGS); goto state_next_arg_begin; } yy62: yyaccept = 0; yych = *(YYMARKER = ++YYCURSOR); @@ -756,7 +755,7 @@ yy63: yych = *++YYCURSOR; goto yy67; yy64: -#line 307 +#line 305 { handle_val(STD_ARGS, 0, '"'); goto state_next_arg_begin; } yy65: yych = *++YYCURSOR; goto yy61; @@ -776,7 +775,7 @@ } yy71: yych = *++YYCURSOR; yy72: -#line 306 +#line 304 { handle_val(STD_ARGS, 1, '\''); goto state_next_arg_begin; } yy73: ++YYCURSOR; if(YYLIMIT == YYCURSOR) YYFILL(1); @@ -785,10 +784,10 @@ if(yych >= '>') goto yy70; yy75: yych = *++YYCURSOR; yy76: -#line 305 +#line 303 { handle_val(STD_ARGS, 1, '"'); goto state_next_arg_begin; } } -#line 309 +#line 307 stop: @@ -801,11 +800,10 @@ ctx->buf.len = rest; } -char *url_adapt_flush(size_t *newlen) +char *url_adapt_flush(size_t *newlen TSRMLS_DC) { char *ret = NULL; url_adapt_state_ex_t *ctx; - TSRMLS_FETCH(); ctx = &BG(url_adapt_state_ex); @@ -819,13 +817,12 @@ return ret; } -char *url_adapt_single_url(const char *url, size_t urllen, const char *name, const char *value, size_t *newlen) +char *url_adapt_single_url(const char *url, size_t urllen, const char *name, const char *value, size_t *newlen TSRMLS_DC) { smart_str surl = {0}; smart_str buf = {0}; smart_str sname = {0}; smart_str sval = {0}; - TSRMLS_FETCH(); smart_str_setl(&surl, url, urllen); smart_str_sets(&sname, name); @@ -839,17 +836,16 @@ return buf.c; } -char *url_adapt_ext(const char *src, size_t srclen, const char *name, const char *value, size_t *newlen) +char *url_adapt_ext(const char *src, size_t srclen, const char *name, const char *value, size_t *newlen TSRMLS_DC) { char *ret; url_adapt_state_ex_t *ctx; - TSRMLS_FETCH(); ctx = &BG(url_adapt_state_ex); smart_str_sets(&ctx->q_name, name); smart_str_sets(&ctx->q_value, value); - mainloop(ctx, src, srclen); + mainloop(ctx, src, srclen TSRMLS_CC); *newlen = ctx->result.len; if (!ctx->result.c) @@ -889,7 +885,9 @@ url_adapt_state_ex_t *ctx; ctx = &BG(url_adapt_state_ex); - ctx->tags = NULL; + + ctx->tags = NULL; + REGISTER_INI_ENTRIES(); return SUCCESS; } Index: php4/ext/standard/url_scanner_ex.h diff -u php4/ext/standard/url_scanner_ex.h:1.11 php4/ext/standard/url_scanner_ex.h:1.12 --- php4/ext/standard/url_scanner_ex.h:1.11 Wed Jul 4 11:30:21 2001 +++ php4/ext/standard/url_scanner_ex.h Sun Aug 5 12:43:57 2001 @@ -24,11 +24,11 @@ PHP_RSHUTDOWN_FUNCTION(url_scanner_ex); PHP_RINIT_FUNCTION(url_scanner_ex); -char *url_adapt_ext_ex(const char *src, size_t srclen, const char *name, const char *value, size_t *newlen); +char *url_adapt_ext_ex(const char *src, size_t srclen, const char *name, const char *value, size_t *newlen TSRMLS_DC); -char *url_adapt_single_url(const char *url, size_t urllen, const char *name, const char *value, size_t *newlen); +char *url_adapt_single_url(const char *url, size_t urllen, const char *name, const char *value, size_t *newlen TSRMLS_DC); -char *url_adapt_flush(size_t *); +char *url_adapt_flush(size_t * TSRMLS_DC); #include "php_smart_str_public.h" Index: php4/ext/standard/url_scanner_ex.re diff -u php4/ext/standard/url_scanner_ex.re:1.33 php4/ext/standard/url_scanner_ex.re:1.34 --- php4/ext/standard/url_scanner_ex.re:1.33 Sat Jul 28 07:36:19 2001 +++ php4/ext/standard/url_scanner_ex.re Sun Aug 5 12:43:57 2001 @@ -45,7 +45,6 @@ char *key; char *lasts; char *tmp; - TSRMLS_FETCH(); ctx = &BG(url_adapt_state_ex); @@ -232,13 +231,12 @@ #define scdebug(x) #endif -static inline void mainloop(url_adapt_state_ex_t *ctx, const char *newdata, size_t newlen) +static inline void mainloop(url_adapt_state_ex_t *ctx, const char *newdata, size_t newlen TSRMLS_DC) { char *end, *q; char *xp; char *start; int rest; - TSRMLS_FETCH(); smart_str_appendl(&ctx->buf, newdata, newlen); @@ -318,11 +316,10 @@ ctx->buf.len = rest; } -char *url_adapt_flush(size_t *newlen) +char *url_adapt_flush(size_t *newlen TSRMLS_DC) { char *ret = NULL; url_adapt_state_ex_t *ctx; - TSRMLS_FETCH(); ctx = &BG(url_adapt_state_ex); @@ -336,13 +333,12 @@ return ret; } -char *url_adapt_single_url(const char *url, size_t urllen, const char *name, const char *value, size_t *newlen) +char *url_adapt_single_url(const char *url, size_t urllen, const char *name, const char *value, size_t *newlen TSRMLS_DC) { smart_str surl = {0}; smart_str buf = {0}; smart_str sname = {0}; smart_str sval = {0}; - TSRMLS_FETCH(); smart_str_setl(&surl, url, urllen); smart_str_sets(&sname, name); @@ -356,17 +352,16 @@ return buf.c; } -char *url_adapt_ext(const char *src, size_t srclen, const char *name, const char *value, size_t *newlen) +char *url_adapt_ext(const char *src, size_t srclen, const char *name, const char *value, size_t *newlen TSRMLS_DC) { char *ret; url_adapt_state_ex_t *ctx; - TSRMLS_FETCH(); ctx = &BG(url_adapt_state_ex); smart_str_sets(&ctx->q_name, name); smart_str_sets(&ctx->q_value, value); - mainloop(ctx, src, srclen); + mainloop(ctx, src, srclen TSRMLS_CC); *newlen = ctx->result.len; if (!ctx->result.c) @@ -379,7 +374,6 @@ PHP_RINIT_FUNCTION(url_scanner) { url_adapt_state_ex_t *ctx; - TSRMLS_FETCH(); ctx = &BG(url_adapt_state_ex); @@ -391,7 +385,6 @@ PHP_RSHUTDOWN_FUNCTION(url_scanner) { url_adapt_state_ex_t *ctx; - TSRMLS_FETCH(); ctx = &BG(url_adapt_state_ex); @@ -406,7 +399,6 @@ PHP_MINIT_FUNCTION(url_scanner) { url_adapt_state_ex_t *ctx; - TSRMLS_FETCH(); ctx = &BG(url_adapt_state_ex); @@ -418,8 +410,6 @@ PHP_MSHUTDOWN_FUNCTION(url_scanner) { - TSRMLS_FETCH(); - UNREGISTER_INI_ENTRIES(); zend_hash_destroy(BG(url_adapt_state_ex).tags); free(BG(url_adapt_state_ex).tags); Index: php4/sapi/apache/php_apache.c diff -u php4/sapi/apache/php_apache.c:1.43 php4/sapi/apache/php_apache.c:1.44 --- php4/sapi/apache/php_apache.c:1.43 Sun Aug 5 11:55:43 2001 +++ php4/sapi/apache/php_apache.c Sun Aug 5 12:43:57 2001 @@ -17,7 +17,7 @@ | David Sklar <sklar@student.net> | +----------------------------------------------------------------------+ */ -/* $Id: php_apache.c,v 1.43 2001/08/05 15:55:43 sas Exp $ */ +/* $Id: php_apache.c,v 1.44 2001/08/05 16:43:57 sas Exp $ */ #define NO_REGEX_EXTRA_H @@ -182,7 +182,6 @@ extern char *user_name; extern gid_t group_id; extern int max_requests_per_child; - TSRMLS_FETCH(); serv = ((request_rec *) SG(server_context))->server;