]> granicus.if.org Git - php/commitdiff
- Fix ZTS build
authorFelipe Pena <felipe@php.net>
Wed, 21 Apr 2010 23:22:20 +0000 (23:22 +0000)
committerFelipe Pena <felipe@php.net>
Wed, 21 Apr 2010 23:22:20 +0000 (23:22 +0000)
sapi/fpm/fpm/fpm_conf.c
sapi/fpm/fpm/fpm_php.c

index f3edc9f05d097f8addd0d66f75af57ac3b880896..89911e1fc8b0ed33408dc8c55723a11953ec3d58 100644 (file)
@@ -43,7 +43,7 @@
 #include "fpm_status.h"
 #include "zlog.h"
 
-static int fpm_conf_load_ini_file(char *filename);
+static int fpm_conf_load_ini_file(char *filename TSRMLS_DC);
 static char *fpm_conf_set_integer(zval *value, void **config, intptr_t offset);
 static char *fpm_conf_set_time(zval *value, void **config, intptr_t offset);
 static char *fpm_conf_set_boolean(zval *value, void **config, intptr_t offset);
@@ -673,7 +673,7 @@ static void fpm_conf_ini_parser_include(char *inc, void *arg TSRMLS_DC) /* {{{ *
                        int len = strlen(g.gl_pathv[i]);
                        if (len < 1) continue;
                        if (g.gl_pathv[i][len - 1] == '/') continue; /* don't parse directories */
-                       if (0 > fpm_conf_load_ini_file(g.gl_pathv[i])) {
+                       if (0 > fpm_conf_load_ini_file(g.gl_pathv[i] TSRMLS_CC)) {
                                zlog(ZLOG_STUFF, ZLOG_ERROR, "Unable to include %s from %s at line %d", g.gl_pathv[i], filename, ini_lineno);
                                *error = 1;
                                return;
@@ -682,7 +682,7 @@ static void fpm_conf_ini_parser_include(char *inc, void *arg TSRMLS_DC) /* {{{ *
                globfree(&g);
        }
 #else /* HAVE_GLOB */
-       if (0 > fpm_conf_load_ini_file(inc)) {
+       if (0 > fpm_conf_load_ini_file(inc TSRMLS_CC)) {
                zlog(ZLOG_STUFF, ZLOG_ERROR, "Unable to include %s from %s at line %d", inc, filename, ini_lineno);
                *error = 1;
                return;
@@ -848,13 +848,13 @@ static void fpm_conf_ini_parser(zval *arg1, zval *arg2, zval *arg3, int callback
 
        switch(callback_type) {
                case ZEND_INI_PARSER_ENTRY:
-                       fpm_conf_ini_parser_entry(arg1, arg2, error);
+                       fpm_conf_ini_parser_entry(arg1, arg2, error TSRMLS_CC);
                        break;;
                case ZEND_INI_PARSER_SECTION:
-                       fpm_conf_ini_parser_section(arg1, error);
+                       fpm_conf_ini_parser_section(arg1, error TSRMLS_CC);
                        break;;
                case ZEND_INI_PARSER_POP_ENTRY:
-                       fpm_conf_ini_parser_array(arg1, arg3, arg2, error);
+                       fpm_conf_ini_parser_array(arg1, arg3, arg2, error TSRMLS_CC);
                        break;;
                default:
                        zlog(ZLOG_STUFF, ZLOG_ERROR, "[%s:%d] Unknown INI syntax", ini_filename, ini_lineno);
@@ -864,7 +864,7 @@ static void fpm_conf_ini_parser(zval *arg1, zval *arg2, zval *arg3, int callback
 }
 /* }}} */
 
-int fpm_conf_load_ini_file(char *filename) /* {{{ */
+int fpm_conf_load_ini_file(char *filename TSRMLS_DC) /* {{{ */
 {
        int error = 0;
        char buf[1024+1];
@@ -936,13 +936,14 @@ int fpm_conf_init_main() /* {{{ */
        char *filename = fpm_globals.config;
        int free = 0;
        int ret;
+       TSRMLS_FETCH();
 
        if (filename == NULL) {
                spprintf(&filename, 0, "%s/php-fpm.conf", PHP_SYSCONFDIR);
                free = 1;
        }
 
-       ret = fpm_conf_load_ini_file(filename);
+       ret = fpm_conf_load_ini_file(filename TSRMLS_CC);
 
        if (0 > ret) {
                zlog(ZLOG_STUFF, ZLOG_ERROR, "failed to load configuration file '%s'", filename);
index a9288ae14037100e9678ebdadd9c7a89875c2713..ce5dac4bcfb45a8816b9c9ae31fb654a234396c6 100644 (file)
@@ -113,7 +113,6 @@ int fpm_php_apply_defines_ex(struct key_value_s *kv, int mode) /* {{{ */
 
 static int fpm_php_apply_defines(struct fpm_worker_pool_s *wp) /* {{{ */
 {
-       TSRMLS_FETCH();
        struct key_value_s *kv;
 
        for (kv = wp->config->php_values; kv; kv = kv->next) {