Skip to content

Commit 4bdd9aa

Browse files
author
George Wang
committed
Fine tuned the order of adding request variables.
1 parent 0cbfdc9 commit 4bdd9aa

File tree

1 file changed

+2
-1
lines changed

1 file changed

+2
-1
lines changed

sapi/litespeed/lsapi_main.c

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -311,6 +311,8 @@ static void sapi_lsapi_register_variables(zval *track_vars_array TSRMLS_DC)
311311
if ( (SG(request_info).request_uri ) )
312312
php_self = (SG(request_info).request_uri );
313313

314+
litespeed_php_import_environment_variables(track_vars_array TSRMLS_CC);
315+
314316
#if ((PHP_MAJOR_VERSION == 5 && PHP_MINOR_VERSION < 4) || PHP_MAJOR_VERSION < 5)
315317
if (!PG(magic_quotes_gpc)) {
316318
#endif
@@ -324,7 +326,6 @@ static void sapi_lsapi_register_variables(zval *track_vars_array TSRMLS_DC)
324326
add_variable_magic_quote("PHP_SELF", 8, php_self, strlen( php_self ), track_vars_array );
325327
}
326328
#endif
327-
litespeed_php_import_environment_variables(track_vars_array TSRMLS_CC);
328329
} else {
329330
php_import_environment_variables(track_vars_array TSRMLS_CC);
330331

0 commit comments

Comments
 (0)