diff options
| author | Zeev Suraski <zeev@php.net> | 2000-11-07 18:25:29 +0000 |
|---|---|---|
| committer | Zeev Suraski <zeev@php.net> | 2000-11-07 18:25:29 +0000 |
| commit | 9e40204f0004a84f45621f1790c29dc52f2784d2 (patch) | |
| tree | 50a7f719f7a9ae9300cebba6d7cb71f9ac5431c8 /main/main.c | |
| parent | 50e0d9d34b9b9669d0fa2682d060ff60ffc7a9e6 (diff) | |
| download | php-git-9e40204f0004a84f45621f1790c29dc52f2784d2.tar.gz | |
@- In CGI mode, $HTTP_SERVER_VARS now includes all of the environment variables
@ as well (Zeev)
Diffstat (limited to 'main/main.c')
| -rw-r--r-- | main/main.c | 10 |
1 files changed, 8 insertions, 2 deletions
diff --git a/main/main.c b/main/main.c index 3a8af10da3..2ef64e9af1 100644 --- a/main/main.c +++ b/main/main.c @@ -1015,7 +1015,10 @@ static int php_hash_environment(ELS_D SLS_DC PLS_DC) } else { p = PG(gpc_order); have_variables_order=0; - php_import_environment_variables(ELS_C PLS_CC); + ALLOC_ZVAL(PG(http_globals)[TRACK_VARS_ENV]); + array_init(PG(http_globals)[TRACK_VARS_ENV]); + INIT_PZVAL(PG(http_globals)[TRACK_VARS_ENV]); + php_import_environment_variables(PG(http_globals)[TRACK_VARS_ENV] ELS_CC PLS_CC); } while(p && *p) { @@ -1044,7 +1047,10 @@ static int php_hash_environment(ELS_D SLS_DC PLS_DC) case 'e': case 'E': if (have_variables_order) { - php_import_environment_variables(ELS_C PLS_CC); + ALLOC_ZVAL(PG(http_globals)[TRACK_VARS_ENV]); + array_init(PG(http_globals)[TRACK_VARS_ENV]); + INIT_PZVAL(PG(http_globals)[TRACK_VARS_ENV]); + php_import_environment_variables(PG(http_globals)[TRACK_VARS_ENV] ELS_CC PLS_CC); } else { php_error(E_WARNING, "Unsupported 'e' element (environment) used in gpc_order - use variables_order instead"); } |
