diff options
author | Pierre Joye <pajoye@php.net> | 2011-01-10 08:28:47 +0000 |
---|---|---|
committer | Pierre Joye <pajoye@php.net> | 2011-01-10 08:28:47 +0000 |
commit | 80e5f0f7743160cf94e4166f95da91cc20d430c3 (patch) | |
tree | 55acbb5b88ece751e5e4aad382ef5e91ce17e8d1 /main/php_ini.c | |
parent | f25ab1bf9c46e0c65399de3fbcae47f3af1ac0b4 (diff) | |
download | php-git-80e5f0f7743160cf94e4166f95da91cc20d430c3.tar.gz |
- remove local redeclaration
Diffstat (limited to 'main/php_ini.c')
-rw-r--r-- | main/php_ini.c | 18 |
1 files changed, 9 insertions, 9 deletions
diff --git a/main/php_ini.c b/main/php_ini.c index d87fce589a..70f2ae7b8e 100644 --- a/main/php_ini.c +++ b/main/php_ini.c @@ -646,14 +646,14 @@ int php_init_config(TSRMLS_D) struct stat sb; char ini_file[MAXPATHLEN]; char *p; - zend_file_handle fh; + zend_file_handle fh2; zend_llist scanned_ini_list; zend_llist_element *element; int l, total_l = 0; if ((ndir = php_scandir(php_ini_scanned_path, &namelist, 0, php_alphasort)) > 0) { zend_llist_init(&scanned_ini_list, sizeof(char *), (llist_dtor_func_t) free_estring, 1); - memset(&fh, 0, sizeof(fh)); + memset(&fh2, 0, sizeof(fh2)); for (i = 0; i < ndir; i++) { @@ -672,11 +672,11 @@ int php_init_config(TSRMLS_D) } if (VCWD_STAT(ini_file, &sb) == 0) { if (S_ISREG(sb.st_mode)) { - if ((fh.handle.fp = VCWD_FOPEN(ini_file, "r"))) { - fh.filename = ini_file; - fh.type = ZEND_HANDLE_FP; + if ((fh2.handle.fp = VCWD_FOPEN(ini_file, "r"))) { + fh2.filename = ini_file; + fh2.type = ZEND_HANDLE_FP; - if (zend_parse_ini_file(&fh, 1, ZEND_INI_SCANNER_NORMAL, (zend_ini_parser_cb_t) php_ini_parser_cb, &configuration_hash TSRMLS_CC) == SUCCESS) { + if (zend_parse_ini_file(&fh2, 1, ZEND_INI_SCANNER_NORMAL, (zend_ini_parser_cb_t) php_ini_parser_cb, &configuration_hash TSRMLS_CC) == SUCCESS) { /* Here, add it to the list of ini files read */ l = strlen(ini_file); total_l += l + 2; @@ -815,7 +815,7 @@ PHPAPI int php_ini_has_per_dir_config(void) */ PHPAPI void php_ini_activate_per_dir_config(char *path, uint path_len TSRMLS_DC) { - zval *tmp; + zval *tmp2; char *ptr; #if PHP_WIN32 @@ -832,8 +832,8 @@ PHPAPI void php_ini_activate_per_dir_config(char *path, uint path_len TSRMLS_DC) while ((ptr = strchr(ptr, '/')) != NULL) { *ptr = 0; /* Search for source array matching the path from configuration_hash */ - if (zend_hash_find(&configuration_hash, path, strlen(path) + 1, (void **) &tmp) == SUCCESS) { - php_ini_activate_config(Z_ARRVAL_P(tmp), PHP_INI_SYSTEM, PHP_INI_STAGE_ACTIVATE TSRMLS_CC); + if (zend_hash_find(&configuration_hash, path, strlen(path) + 1, (void **) &tmp2) == SUCCESS) { + php_ini_activate_config(Z_ARRVAL_P(tmp2), PHP_INI_SYSTEM, PHP_INI_STAGE_ACTIVATE TSRMLS_CC); } *ptr = '/'; ptr++; |