sebastian               Tue Mar 25 03:07:14 2003 EDT

  Modified files:              
    /php4/ext/ftp       ftp.c 
    /php4/ext/pcre      php_pcre.c php_pcre.h 
    /php4/ext/session   session.c 
    /php4/ext/standard  aggregation.c basic_functions.c credits.c 
                        credits.h css.c css.h datetime.c datetime.h 
                        head.c head.h info.c info.h levenshtein.c 
    /php4/main  output.c php_variables.c 
    /php4/sapi/apache   php_apache.c 
    /php4/sapi/apache2handler   php_functions.c 
    /php4/sapi/apache_hooks     php_apache.c 
    /php4/sapi/cgi      cgi_main.c 
    /php4/sapi/cli      php_cli.c 
    /php4/sapi/servlet  servlet.c 
  Log:
  Eliminate some TSRMLS_FETCH() calls. Tested with Win32 build of SAPI/CGI and 
SAPI/CLI on Win32.
  
Index: php4/ext/ftp/ftp.c
diff -u php4/ext/ftp/ftp.c:1.84 php4/ext/ftp/ftp.c:1.85
--- php4/ext/ftp/ftp.c:1.84     Tue Mar 18 12:30:32 2003
+++ php4/ext/ftp/ftp.c  Tue Mar 25 03:07:11 2003
@@ -17,7 +17,7 @@
    +----------------------------------------------------------------------+
  */
 
-/* $Id: ftp.c,v 1.84 2003/03/18 17:30:32 sniper Exp $ */
+/* $Id: ftp.c,v 1.85 2003/03/25 08:07:11 sebastian Exp $ */
 
 #include "php.h"
 
@@ -103,7 +103,7 @@
 static databuf_t*      ftp_getdata(ftpbuf_t *ftp TSRMLS_DC);
 
 /* accepts the data connection, returns updated data buffer */
-static databuf_t*      data_accept(databuf_t *data, ftpbuf_t *ftp);
+static databuf_t*      data_accept(databuf_t *data, ftpbuf_t *ftp TSRMLS_DC);
 
 /* closes the data connection, returns NULL */
 static databuf_t*      data_close(ftpbuf_t *ftp, databuf_t *data);
@@ -790,7 +790,7 @@
                goto bail;
        }
 
-       if ((data = data_accept(data, ftp)) == NULL) {
+       if ((data = data_accept(data, ftp TSRMLS_CC)) == NULL) {
                goto bail;
        }
 
@@ -874,7 +874,7 @@
        if (!ftp_getresp(ftp) || (ftp->resp != 150 && ftp->resp != 125)) {
                goto bail;
        }
-       if ((data = data_accept(data, ftp)) == NULL) {
+       if ((data = data_accept(data, ftp TSRMLS_CC)) == NULL) {
                goto bail;
        }
 
@@ -1469,14 +1469,13 @@
 /* {{{ data_accept
  */
 databuf_t*
-data_accept(databuf_t *data, ftpbuf_t *ftp)
+data_accept(databuf_t *data, ftpbuf_t *ftp TSRMLS_DC)
 {
        php_sockaddr_storage addr;
        socklen_t                       size;
 
 #if HAVE_OPENSSL_EXT
        SSL_CTX         *ctx;
-       TSRMLS_FETCH(); 
 #endif
 
        if (data->fd != -1) {
@@ -1603,7 +1602,7 @@
        }
 
        /* pull data buffer into tmpfile */
-       if ((data = data_accept(data, ftp)) == NULL) {
+       if ((data = data_accept(data, ftp TSRMLS_CC)) == NULL) {
                goto bail;
        }
        size = 0;
@@ -1717,7 +1716,7 @@
                goto bail;
        }
 
-       if ((data = data_accept(data, ftp)) == NULL) {
+       if ((data = data_accept(data, ftp TSRMLS_CC)) == NULL) {
                goto bail;
        }
 
@@ -1834,7 +1833,7 @@
        if (!ftp_getresp(ftp) || (ftp->resp != 150 && ftp->resp != 125)) {
                goto bail;
        }
-       if ((data = data_accept(data, ftp)) == NULL) { 
+       if ((data = data_accept(data, ftp TSRMLS_CC)) == NULL) { 
                goto bail;
        }
        ftp->data = data;
Index: php4/ext/pcre/php_pcre.c
diff -u php4/ext/pcre/php_pcre.c:1.138 php4/ext/pcre/php_pcre.c:1.139
--- php4/ext/pcre/php_pcre.c:1.138      Fri Jan 24 00:21:08 2003
+++ php4/ext/pcre/php_pcre.c    Tue Mar 25 03:07:12 2003
@@ -16,7 +16,7 @@
    +----------------------------------------------------------------------+
  */
 
-/* $Id: php_pcre.c,v 1.138 2003/01/24 05:21:08 iliaa Exp $ */
+/* $Id: php_pcre.c,v 1.139 2003/03/25 08:07:12 sebastian Exp $ */
 
 #ifdef HAVE_CONFIG_H
 #include "config.h"
@@ -131,7 +131,7 @@
 
 /* {{{ pcre_get_compiled_regex
  */
-PHPAPI pcre* pcre_get_compiled_regex(char *regex, pcre_extra **extra, int 
*preg_options) {
+PHPAPI pcre* pcre_get_compiled_regex(char *regex, pcre_extra **extra, int 
*preg_options TSRMLS_DC) {
        pcre                            *re = NULL;
        int                                      coptions = 0;
        int                                      soptions = 0;
@@ -151,7 +151,6 @@
 #endif
        pcre_cache_entry        *pce;
        pcre_cache_entry         new_entry;
-       TSRMLS_FETCH();
 
        /* Try to lookup the cached regex entry, and if successful, just pass
           back the compiled pattern, otherwise go on and compile it. */
@@ -408,7 +407,7 @@
        }
 
        /* Compile regex or get it from cache. */
-       if ((re = pcre_get_compiled_regex(Z_STRVAL_PP(regex), &extra, &preg_options)) 
== NULL) {
+       if ((re = pcre_get_compiled_regex(Z_STRVAL_PP(regex), &extra, &preg_options 
TSRMLS_CC)) == NULL) {
                RETURN_FALSE;
        }
 
@@ -612,14 +611,13 @@
 
 /* {{{ preg_do_repl_func
  */
-static int preg_do_repl_func(zval *function, char *subject, int *offsets, int count, 
char **result)
+static int preg_do_repl_func(zval *function, char *subject, int *offsets, int count, 
char **result TSRMLS_DC)
 {
        zval            *retval_ptr;            /* Function return value */
        zval       **args[1];                   /* Argument to pass to function */
        zval            *subpats;                       /* Captured subpatterns */ 
        int                      result_len;            /* Return value length */
        int                      i;
-       TSRMLS_FETCH();
 
        MAKE_STD_ZVAL(subpats);
        array_init(subpats);
@@ -769,7 +767,7 @@
                                         walk_last;                     /* Last walked 
character */
 
        /* Compile regex or get it from cache. */
-       if ((re = pcre_get_compiled_regex(regex, &extra, &preg_options)) == NULL) {
+       if ((re = pcre_get_compiled_regex(regex, &extra, &preg_options TSRMLS_CC)) == 
NULL) {
                return NULL;
        }
 
@@ -824,7 +822,7 @@
                        } else if (is_callable_replace) {
                                /* Use custom function to get replacement string and 
its length. */
                                eval_result_len = preg_do_repl_func(replace_val, 
subject, offsets,
-                                                                                      
                 count, &eval_result);
+                                                                                      
                 count, &eval_result TSRMLS_CC);
                                new_len += eval_result_len;
                        } else { /* do regular substitution */
                                walk = replace;
@@ -1174,7 +1172,7 @@
        convert_to_string_ex(subject);
        
        /* Compile regex or get it from cache. */
-       if ((re = pcre_get_compiled_regex(Z_STRVAL_PP(regex), &extra, &preg_options)) 
== NULL) {
+       if ((re = pcre_get_compiled_regex(Z_STRVAL_PP(regex), &extra, &preg_options 
TSRMLS_CC)) == NULL) {
                RETURN_FALSE;
        }
        
@@ -1408,7 +1406,7 @@
        }
        
        /* Compile regex or get it from cache. */
-       if ((re = pcre_get_compiled_regex(Z_STRVAL_PP(regex), &extra, &preg_options)) 
== NULL) {
+       if ((re = pcre_get_compiled_regex(Z_STRVAL_PP(regex), &extra, &preg_options 
TSRMLS_CC)) == NULL) {
                RETURN_FALSE;
        }
 
Index: php4/ext/pcre/php_pcre.h
diff -u php4/ext/pcre/php_pcre.h:1.34 php4/ext/pcre/php_pcre.h:1.35
--- php4/ext/pcre/php_pcre.h:1.34       Tue Dec 31 11:07:12 2002
+++ php4/ext/pcre/php_pcre.h    Tue Mar 25 03:07:12 2003
@@ -16,7 +16,7 @@
    +----------------------------------------------------------------------+
  */
  
-/* $Id: php_pcre.h,v 1.34 2002/12/31 16:07:12 sebastian Exp $ */
+/* $Id: php_pcre.h,v 1.35 2003/03/25 08:07:12 sebastian Exp $ */
 
 #ifndef PHP_PCRE_H
 #define PHP_PCRE_H
@@ -42,7 +42,7 @@
 PHP_FUNCTION(preg_grep);
 
 PHPAPI char *php_pcre_replace(char *regex,   int regex_len, char *subject, int 
subject_len, zval *replace_val, int is_callable_replace, int *result_len, int limit 
TSRMLS_DC);
-PHPAPI pcre* pcre_get_compiled_regex(char *regex, pcre_extra **extra, int *options);
+PHPAPI pcre* pcre_get_compiled_regex(char *regex, pcre_extra **extra, int *options 
TSRMLS_DC);
 
 extern zend_module_entry pcre_module_entry;
 #define pcre_module_ptr &pcre_module_entry
Index: php4/ext/session/session.c
diff -u php4/ext/session/session.c:1.357 php4/ext/session/session.c:1.358
--- php4/ext/session/session.c:1.357    Fri Mar  7 00:15:22 2003
+++ php4/ext/session/session.c  Tue Mar 25 03:07:12 2003
@@ -17,7 +17,7 @@
    +----------------------------------------------------------------------+
  */
 
-/* $Id: session.c,v 1.357 2003/03/07 05:15:22 sniper Exp $ */
+/* $Id: session.c,v 1.358 2003/03/25 08:07:12 sebastian Exp $ */
 
 #ifdef HAVE_CONFIG_H
 #include "config.h"
@@ -959,7 +959,7 @@
                struct timeval tv;
                
                gettimeofday(&tv, NULL);
-               date_fmt = php_std_date(tv.tv_sec + PS(cookie_lifetime));
+               date_fmt = php_std_date(tv.tv_sec + PS(cookie_lifetime) TSRMLS_CC);
                
                smart_str_appends(&ncookie, COOKIE_EXPIRES);
                smart_str_appends(&ncookie, date_fmt);
Index: php4/ext/standard/aggregation.c
diff -u php4/ext/standard/aggregation.c:1.19 php4/ext/standard/aggregation.c:1.20
--- php4/ext/standard/aggregation.c:1.19        Mon Mar 17 08:06:51 2003
+++ php4/ext/standard/aggregation.c     Tue Mar 25 03:07:12 2003
@@ -16,7 +16,7 @@
    +----------------------------------------------------------------------+
 */
 
-/* $Id: aggregation.c,v 1.19 2003/03/17 13:06:51 hholzgra Exp $ */
+/* $Id: aggregation.c,v 1.20 2003/03/25 08:07:12 sebastian Exp $ */
 
 #include "php.h"
 #include "basic_functions.h"
@@ -100,7 +100,7 @@
        }
 #if (HAVE_PCRE || HAVE_BUNDLED_PCRE) && !defined(COMPILE_DL_PCRE)
        else if (aggr_type == AGGREGATE_BY_REGEXP) {
-               if ((re = pcre_get_compiled_regex(Z_STRVAL_P(aggr_filter), &re_extra, 
&re_options)) == NULL) {
+               if ((re = pcre_get_compiled_regex(Z_STRVAL_P(aggr_filter), &re_extra, 
&re_options TSRMLS_CC)) == NULL) {
                        return;
                }
        }
@@ -206,7 +206,7 @@
        }
 #if (HAVE_PCRE || HAVE_BUNDLED_PCRE) && !defined(COMPILE_DL_PCRE)
        else if (aggr_type == AGGREGATE_BY_REGEXP) {
-               if ((re = pcre_get_compiled_regex(Z_STRVAL_P(aggr_filter), &re_extra, 
&re_options)) == NULL) {
+               if ((re = pcre_get_compiled_regex(Z_STRVAL_P(aggr_filter), &re_extra, 
&re_options TSRMLS_CC)) == NULL) {
                        return;
                }
        }
Index: php4/ext/standard/basic_functions.c
diff -u php4/ext/standard/basic_functions.c:1.596 
php4/ext/standard/basic_functions.c:1.597
--- php4/ext/standard/basic_functions.c:1.596   Wed Mar 12 01:47:34 2003
+++ php4/ext/standard/basic_functions.c Tue Mar 25 03:07:12 2003
@@ -17,7 +17,7 @@
    +----------------------------------------------------------------------+
  */
 
-/* $Id: basic_functions.c,v 1.596 2003/03/12 06:47:34 sterling Exp $ */
+/* $Id: basic_functions.c,v 1.597 2003/03/25 08:07:12 sebastian Exp $ */
 
 #include "php.h"
 #include "php_streams.h"
@@ -2919,8 +2919,6 @@
                        convert_to_boolean_ex(process_sections);
                
                        if (Z_BVAL_PP(process_sections)) {
-                               TSRMLS_FETCH();
-
                                BG(active_ini_file_section) = NULL;
                                ini_parser_cb = (zend_ini_parser_cb_t) 
php_ini_parser_cb_with_sections;
                        } else {
Index: php4/ext/standard/credits.c
diff -u php4/ext/standard/credits.c:1.26 php4/ext/standard/credits.c:1.27
--- php4/ext/standard/credits.c:1.26    Mon Jan 20 07:34:07 2003
+++ php4/ext/standard/credits.c Tue Mar 25 03:07:12 2003
@@ -17,7 +17,7 @@
    +----------------------------------------------------------------------+
 */
 
-/* $Id: credits.c,v 1.26 2003/01/20 12:34:07 derick Exp $ */
+/* $Id: credits.c,v 1.27 2003/03/25 08:07:12 sebastian Exp $ */
 
 #include "php.h"
 #include "info.h"
@@ -26,10 +26,8 @@
 
 /* {{{ php_print_credits
  */
-PHPAPI void php_print_credits(int flag)
+PHPAPI void php_print_credits(int flag TSRMLS_DC)
 {
-       TSRMLS_FETCH();
-
        if (flag & PHP_CREDITS_FULLPAGE) {
                php_print_info_htmlhead(TSRMLS_C);
        }
Index: php4/ext/standard/credits.h
diff -u php4/ext/standard/credits.h:1.7 php4/ext/standard/credits.h:1.8
--- php4/ext/standard/credits.h:1.7     Tue Dec 31 11:07:34 2002
+++ php4/ext/standard/credits.h Tue Mar 25 03:07:12 2003
@@ -17,7 +17,7 @@
    +----------------------------------------------------------------------+
 */
 
-/* $Id: credits.h,v 1.7 2002/12/31 16:07:34 sebastian Exp $ */
+/* $Id: credits.h,v 1.8 2003/03/25 08:07:12 sebastian Exp $ */
 
 #ifndef CREDITS_H
 #define CREDITS_H
@@ -37,6 +37,6 @@
 
 #endif /* HAVE_CREDITS_DEFS */
 
-PHPAPI void php_print_credits(int flag);
+PHPAPI void php_print_credits(int flag TSRMLS_DC);
 
 #endif
Index: php4/ext/standard/css.c
diff -u php4/ext/standard/css.c:1.7 php4/ext/standard/css.c:1.8
--- php4/ext/standard/css.c:1.7 Tue Dec 31 11:07:34 2002
+++ php4/ext/standard/css.c     Tue Mar 25 03:07:12 2003
@@ -16,7 +16,7 @@
    +----------------------------------------------------------------------+
 */
 
-/* $Id: css.c,v 1.7 2002/12/31 16:07:34 sebastian Exp $ */
+/* $Id: css.c,v 1.8 2003/03/25 08:07:12 sebastian Exp $ */
 
 #include "php.h"
 #include "info.h"
@@ -24,10 +24,8 @@
 
 /* {{{ php_info_print_css
  */
-PHPAPI void php_info_print_css(void)
+PHPAPI void php_info_print_css(TSRMLS_D)
 {
-       TSRMLS_FETCH();
-
        PUTS("body {background-color: #ffffff; color: #000000;}\n");
        PUTS("body, td, th, h1, h2 {font-family: sans-serif;}\n");
        PUTS("pre {margin: 0px; font-family: monospace;}\n");
Index: php4/ext/standard/css.h
diff -u php4/ext/standard/css.h:1.2 php4/ext/standard/css.h:1.3
--- php4/ext/standard/css.h:1.2 Tue Dec 31 11:07:34 2002
+++ php4/ext/standard/css.h     Tue Mar 25 03:07:12 2003
@@ -16,11 +16,11 @@
    +----------------------------------------------------------------------+
 */
 
-/* $Id: css.h,v 1.2 2002/12/31 16:07:34 sebastian Exp $ */
+/* $Id: css.h,v 1.3 2003/03/25 08:07:12 sebastian Exp $ */
 
 #ifndef CSS_H
 #define CSS_H
 
-PHPAPI void php_info_print_css(void);
+PHPAPI void php_info_print_css(TSRMLS_D);
 
 #endif
Index: php4/ext/standard/datetime.c
diff -u php4/ext/standard/datetime.c:1.106 php4/ext/standard/datetime.c:1.107
--- php4/ext/standard/datetime.c:1.106  Mon Feb 17 01:28:06 2003
+++ php4/ext/standard/datetime.c        Tue Mar 25 03:07:12 2003
@@ -18,7 +18,7 @@
    +----------------------------------------------------------------------+
  */
 
-/* $Id: datetime.c,v 1.106 2003/02/17 06:28:06 sniper Exp $ */
+/* $Id: datetime.c,v 1.107 2003/03/25 08:07:12 sebastian Exp $ */
 
 #include "php.h"
 #include "zend_operators.h"
@@ -881,11 +881,10 @@
 
 /* {{{ php_std_date
    Return date string in standard format for http headers */
-char *php_std_date(time_t t)
+char *php_std_date(time_t t TSRMLS_DC)
 {
        struct tm *tm1, tmbuf;
        char *str;
-       TSRMLS_FETCH();
 
        tm1 = php_gmtime_r(&t, &tmbuf);
        str = emalloc(81);
Index: php4/ext/standard/datetime.h
diff -u php4/ext/standard/datetime.h:1.13 php4/ext/standard/datetime.h:1.14
--- php4/ext/standard/datetime.h:1.13   Mon Feb 17 01:28:06 2003
+++ php4/ext/standard/datetime.h        Tue Mar 25 03:07:12 2003
@@ -17,7 +17,7 @@
    +----------------------------------------------------------------------+
 */
 
-/* $Id: datetime.h,v 1.13 2003/02/17 06:28:06 sniper Exp $ */
+/* $Id: datetime.h,v 1.14 2003/03/25 08:07:12 sebastian Exp $ */
 
 #ifndef DATETIME_H
 #define DATETIME_H
@@ -38,7 +38,7 @@
 PHP_FUNCTION(strtotime);
 
 int php_idate(char format, int timestamp, int gm);
-extern char *php_std_date(time_t t);
+extern char *php_std_date(time_t t TSRMLS_DC);
 void php_mktime(INTERNAL_FUNCTION_PARAMETERS, int gm);
 #if HAVE_STRFTIME
 void _php_strftime(INTERNAL_FUNCTION_PARAMETERS, int gm);
Index: php4/ext/standard/head.c
diff -u php4/ext/standard/head.c:1.68 php4/ext/standard/head.c:1.69
--- php4/ext/standard/head.c:1.68       Thu Mar  6 18:07:27 2003
+++ php4/ext/standard/head.c    Tue Mar 25 03:07:12 2003
@@ -15,7 +15,7 @@
    | Author: Rasmus Lerdorf <[EMAIL PROTECTED]>                        |
    +----------------------------------------------------------------------+
  */
-/* $Id: head.c,v 1.68 2003/03/06 23:07:27 ddhill Exp $ */
+/* $Id: head.c,v 1.69 2003/03/25 08:07:12 sebastian Exp $ */
 
 #include <stdio.h>
 
@@ -55,10 +55,8 @@
 }
 /* }}} */
 
-PHPAPI int php_header()
+PHPAPI int php_header(TSRMLS_D)
 {
-       TSRMLS_FETCH();
-
        if (sapi_send_headers(TSRMLS_C)==FAILURE || SG(request_info).headers_only) {
                return 0; /* don't allow output */
        } else {
@@ -98,14 +96,14 @@
                 * pick an expiry date 1 year and 1 second in the past
                 */
                t = time(NULL) - 31536001;
-               dt = php_std_date(t);
+               dt = php_std_date(t TSRMLS_CC);
                sprintf(cookie, "Set-Cookie: %s=deleted; expires=%s", name, dt);
                efree(dt);
        } else {
                sprintf(cookie, "Set-Cookie: %s=%s", name, value ? encoded_value : "");
                if (expires > 0) {
                        strcat(cookie, "; expires=");
-                       dt = php_std_date(expires);
+                       dt = php_std_date(expires TSRMLS_CC);
                        strcat(cookie, dt);
                        efree(dt);
                }
Index: php4/ext/standard/head.h
diff -u php4/ext/standard/head.h:1.22 php4/ext/standard/head.h:1.23
--- php4/ext/standard/head.h:1.22       Tue Dec 31 11:07:42 2002
+++ php4/ext/standard/head.h    Tue Mar 25 03:07:12 2003
@@ -16,7 +16,7 @@
    +----------------------------------------------------------------------+
 */
 
-/* $Id: head.h,v 1.22 2002/12/31 16:07:42 sebastian Exp $ */
+/* $Id: head.h,v 1.23 2003/03/25 08:07:12 sebastian Exp $ */
 
 #ifndef HEAD_H
 #define HEAD_H
@@ -26,7 +26,7 @@
 PHP_FUNCTION(setcookie);
 PHP_FUNCTION(headers_sent);
 
-PHPAPI int php_header(void);
+PHPAPI int php_header(TSRMLS_D);
 PHPAPI int php_setcookie(char *name, int name_len, char *value, int value_len, time_t 
expires, char *path, int path_len, char *domain, int domain_len, int secure TSRMLS_DC);
 
 #endif
Index: php4/ext/standard/info.c
diff -u php4/ext/standard/info.c:1.229 php4/ext/standard/info.c:1.230
--- php4/ext/standard/info.c:1.229      Tue Mar 18 15:52:51 2003
+++ php4/ext/standard/info.c    Tue Mar 25 03:07:12 2003
@@ -18,7 +18,7 @@
    +----------------------------------------------------------------------+
 */
 
-/* $Id: info.c,v 1.229 2003/03/18 20:52:51 helly Exp $ */
+/* $Id: info.c,v 1.230 2003/03/25 08:07:12 sebastian Exp $ */
 
 #include "php.h"
 #include "php_ini.h"
@@ -184,10 +184,10 @@
 
 /* {{{ php_info_print_style
  */
-void php_info_print_style(void)
+void php_info_print_style(TSRMLS_D)
 {
        php_printf("<style type=\"text/css\"><!--\n");
-       php_info_print_css();
+       php_info_print_css(TSRMLS_C);
        php_printf("//--></style>\n");
 }
 /* }}} */
@@ -357,7 +357,7 @@
        PUTS("<!DOCTYPE html PUBLIC \"-//W3C//DTD XHTML 1.0 Transitional//EN\" 
\"DTD/xhtml1-transitional.dtd\">\n");
        PUTS("<html>");
        PUTS("<head>\n");
-       php_info_print_style();
+       php_info_print_style(TSRMLS_C);
        PUTS("<title>phpinfo()</title>");
 /*
        php_printf("<meta http-equiv=\"Content-Type\" content=\"text/html; 
charset=%s\" />\n", charset);
@@ -897,7 +897,7 @@
                flag = PHP_CREDITS_ALL;
        } 
 
-       php_print_credits(flag);
+       php_print_credits(flag TSRMLS_CC);
        RETURN_TRUE;
 }
 /* }}} */
Index: php4/ext/standard/info.h
diff -u php4/ext/standard/info.h:1.30 php4/ext/standard/info.h:1.31
--- php4/ext/standard/info.h:1.30       Tue Dec 31 11:07:45 2002
+++ php4/ext/standard/info.h    Tue Mar 25 03:07:12 2003
@@ -17,7 +17,7 @@
    +----------------------------------------------------------------------+
 */
 
-/* $Id: info.h,v 1.30 2002/12/31 16:07:45 sebastian Exp $ */
+/* $Id: info.h,v 1.31 2003/03/25 08:07:12 sebastian Exp $ */
 
 #ifndef INFO_H
 #define INFO_H
@@ -68,7 +68,7 @@
 PHPAPI void php_print_info_htmlhead(TSRMLS_D);
 PHPAPI void php_print_info(int flag TSRMLS_DC);
 PHPAPI void php_print_style(void);
-PHPAPI void php_info_print_style(void);
+PHPAPI void php_info_print_style(TSRMLS_D);
 PHPAPI void php_info_print_table_colspan_header(int num_cols, char *header);
 PHPAPI void php_info_print_table_header(int num_cols, ...);
 PHPAPI void php_info_print_table_row(int num_cols, ...);
Index: php4/ext/standard/levenshtein.c
diff -u php4/ext/standard/levenshtein.c:1.28 php4/ext/standard/levenshtein.c:1.29
--- php4/ext/standard/levenshtein.c:1.28        Tue Dec 31 11:07:45 2002
+++ php4/ext/standard/levenshtein.c     Tue Mar 25 03:07:12 2003
@@ -15,7 +15,7 @@
    | Author: Hartmut Holzgraefe <[EMAIL PROTECTED]>                        |
    +----------------------------------------------------------------------+
  */
-/* $Id: levenshtein.c,v 1.28 2002/12/31 16:07:45 sebastian Exp $ */
+/* $Id: levenshtein.c,v 1.29 2003/03/25 08:07:12 sebastian Exp $ */
 
 #include "php.h"
 #include <stdlib.h>
@@ -75,10 +75,8 @@
 
 /* {{{ custom_levdist
  */
-static int custom_levdist(char *str1, char *str2, char *callback_name) 
+static int custom_levdist(char *str1, char *str2, char *callback_name TSRMLS_DC) 
 {
-       TSRMLS_FETCH();
-
        php_error_docref(NULL TSRMLS_CC, E_WARNING, "The general Levenshtein support 
is not there yet");
        /* not there yet */
 
@@ -132,7 +130,7 @@
                convert_to_string_ex(callback_name);
 
                distance = custom_levdist(Z_STRVAL_PP(str1), Z_STRVAL_PP(str2),
-                                                                 
Z_STRVAL_PP(callback_name));
+                                                                 
Z_STRVAL_PP(callback_name) TSRMLS_CC);
                break;
 
        default: 
Index: php4/main/output.c
diff -u php4/main/output.c:1.149 php4/main/output.c:1.150
--- php4/main/output.c:1.149    Thu Mar  6 18:07:28 2003
+++ php4/main/output.c  Tue Mar 25 03:07:12 2003
@@ -18,7 +18,7 @@
    +----------------------------------------------------------------------+
 */
 
-/* $Id: output.c,v 1.149 2003/03/06 23:07:28 ddhill Exp $ */
+/* $Id: output.c,v 1.150 2003/03/25 08:07:12 sebastian Exp $ */
 
 #include "php.h"
 #include "ext/standard/head.h"
@@ -683,10 +683,10 @@
        int result = 0;
 
        if (SG(request_info).headers_only) {
-               php_header();
+               php_header(TSRMLS_C);
                zend_bailout();
        }
-       if (php_header()) {
+       if (php_header(TSRMLS_C)) {
                if (zend_is_compiling(TSRMLS_C)) {
                        OG(output_start_filename) = 
zend_get_compiled_filename(TSRMLS_C);
                        OG(output_start_lineno) = zend_get_compiled_lineno(TSRMLS_C);
Index: php4/main/php_variables.c
diff -u php4/main/php_variables.c:1.56 php4/main/php_variables.c:1.57
--- php4/main/php_variables.c:1.56      Sun Mar 23 14:30:31 2003
+++ php4/main/php_variables.c   Tue Mar 25 03:07:12 2003
@@ -17,7 +17,7 @@
    +----------------------------------------------------------------------+
  */
 
-/* $Id: php_variables.c,v 1.56 2003/03/23 19:30:31 shane Exp $ */
+/* $Id: php_variables.c,v 1.57 2003/03/25 08:07:12 sebastian Exp $ */
 
 #include <stdio.h>
 #include "php.h"
@@ -454,7 +454,7 @@
                if (php_info_logos(SG(request_info).query_string+1 TSRMLS_CC)) {
                        return 1;
                } else if (!strcmp(SG(request_info).query_string+1, PHP_CREDITS_GUID)) 
{
-                       php_print_credits(PHP_CREDITS_ALL);
+                       php_print_credits(PHP_CREDITS_ALL TSRMLS_CC);
                        return 1;
                }
        }
Index: php4/sapi/apache/php_apache.c
diff -u php4/sapi/apache/php_apache.c:1.79 php4/sapi/apache/php_apache.c:1.80
--- php4/sapi/apache/php_apache.c:1.79  Tue Mar 18 07:06:08 2003
+++ php4/sapi/apache/php_apache.c       Tue Mar 25 03:07:13 2003
@@ -17,7 +17,7 @@
    |          David Sklar <[EMAIL PROTECTED]>                             |
    +----------------------------------------------------------------------+
  */
-/* $Id: php_apache.c,v 1.79 2003/03/18 12:06:08 ssb Exp $ */
+/* $Id: php_apache.c,v 1.80 2003/03/25 08:07:13 sebastian Exp $ */
 
 #include "php_apache_http.h"
 
@@ -321,7 +321,7 @@
        }
 
        php_end_ob_buffers(1 TSRMLS_CC);
-       php_header();
+       php_header(TSRMLS_C);
 
        if (run_sub_req(rr)) {
                php_error_docref(NULL TSRMLS_CC, E_WARNING, "Unable to include '%s' - 
request execution failed", (*filename)->value.str.val);
Index: php4/sapi/apache2handler/php_functions.c
diff -u php4/sapi/apache2handler/php_functions.c:1.5 
php4/sapi/apache2handler/php_functions.c:1.6
--- php4/sapi/apache2handler/php_functions.c:1.5        Mon Mar 24 20:38:14 2003
+++ php4/sapi/apache2handler/php_functions.c    Tue Mar 25 03:07:13 2003
@@ -16,7 +16,7 @@
    +----------------------------------------------------------------------+
  */
 
-/* $Id: php_functions.c,v 1.5 2003/03/25 01:38:14 sniper Exp $ */
+/* $Id: php_functions.c,v 1.6 2003/03/25 08:07:13 sebastian Exp $ */
 
 #include "php.h"
 #include "ext/standard/php_smart_str.h"
@@ -92,7 +92,7 @@
 
        /* Flush everything. */
        php_end_ob_buffers(1 TSRMLS_CC);
-       php_header();
+       php_header(TSRMLS_C);
 
        if (ap_run_sub_req(rr)) {
                php_error_docref(NULL TSRMLS_CC, E_WARNING, "Unable to include '%s' - 
request execution failed", Z_STRVAL_PP(filename));
Index: php4/sapi/apache_hooks/php_apache.c
diff -u php4/sapi/apache_hooks/php_apache.c:1.12 
php4/sapi/apache_hooks/php_apache.c:1.13
--- php4/sapi/apache_hooks/php_apache.c:1.12    Tue Mar 18 07:06:08 2003
+++ php4/sapi/apache_hooks/php_apache.c Tue Mar 25 03:07:13 2003
@@ -17,7 +17,7 @@
    |          David Sklar <[EMAIL PROTECTED]>                             |
    +----------------------------------------------------------------------+
  */
-/* $Id: php_apache.c,v 1.12 2003/03/18 12:06:08 ssb Exp $ */
+/* $Id: php_apache.c,v 1.13 2003/03/25 08:07:13 sebastian Exp $ */
 
 #include "php_apache_http.h"
 
@@ -1732,7 +1732,7 @@
        }
 
        php_end_ob_buffers(1 TSRMLS_CC);
-       php_header();
+       php_header(TSRMLS_C);
 
        if (run_sub_req(rr)) {
                php_error(E_WARNING, "Unable to include '%s' - request execution 
failed", (*filename)->value.str.val);
Index: php4/sapi/cgi/cgi_main.c
diff -u php4/sapi/cgi/cgi_main.c:1.218 php4/sapi/cgi/cgi_main.c:1.219
--- php4/sapi/cgi/cgi_main.c:1.218      Tue Mar 25 02:43:30 2003
+++ php4/sapi/cgi/cgi_main.c    Tue Mar 25 03:07:13 2003
@@ -20,7 +20,7 @@
    +----------------------------------------------------------------------+
 */
 
-/* $Id: cgi_main.c,v 1.218 2003/03/25 07:43:30 shane Exp $ */
+/* $Id: cgi_main.c,v 1.219 2003/03/25 08:07:13 sebastian Exp $ */
 
 #include "php.h"
 #include "php_globals.h"
@@ -464,7 +464,9 @@
 
 static void sapi_cgi_log_message(char *message)
 {
-       if (php_header()) {
+       TSRMLS_FETCH();
+
+       if (php_header(TSRMLS_C)) {
                fprintf(stderr, "%s", message);
                fprintf(stderr, "\n");
        }
Index: php4/sapi/cli/php_cli.c
diff -u php4/sapi/cli/php_cli.c:1.74 php4/sapi/cli/php_cli.c:1.75
--- php4/sapi/cli/php_cli.c:1.74        Wed Mar 19 15:36:04 2003
+++ php4/sapi/cli/php_cli.c     Tue Mar 25 03:07:13 2003
@@ -238,7 +238,9 @@
 
 static void sapi_cli_log_message(char *message)
 {
-       if (php_header()) {
+       TSRMLS_FETCH();
+
+       if (php_header(TSRMLS_C)) {
                fprintf(stderr, "%s", message);
                fprintf(stderr, "\n");
        }
Index: php4/sapi/servlet/servlet.c
diff -u php4/sapi/servlet/servlet.c:1.70 php4/sapi/servlet/servlet.c:1.71
--- php4/sapi/servlet/servlet.c:1.70    Thu Mar  6 15:31:20 2003
+++ php4/sapi/servlet/servlet.c Tue Mar 25 03:07:13 2003
@@ -375,7 +375,7 @@
                        }
                } else {
                        php_execute_script(&file_handle TSRMLS_CC);
-                       php_header();                   /* Make sure headers have been 
sent */
+                       php_header(TSRMLS_C);                   /* Make sure headers 
have been sent */
                }
 
                /*

-- 
PHP CVS Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php

Reply via email to