Permalink
Browse files

Changed priority of PHPRC environment variable on win32 to be higher …

…then value from registry.
  • Loading branch information...
1 parent a32fb32 commit acb1e079806a107b9d5e048260985223028f3612 Dmitry Stogov committed Jul 4, 2006
Showing with 10 additions and 8 deletions.
  1. +2 −0 NEWS
  2. +8 −8 main/php_ini.c
View
2 NEWS
@@ -3,6 +3,8 @@ PHP NEWS
?? ??? 2006, PHP 5.2.0
- Reimplementation of Apache2Filter, PHP can now be an arbitrary filter
in the chain and will read the script from the Apache stream. (John)
+- Changed priority of PHPRC environment variable on win32 to be higher then
+ value from registry. (Dmitry)
- Changed __toString() to be called wherever applicable. (Marcus)
- Changed E_ALL error reporting mode to include E_RECOVERABLE_ERROR. (Marcus)
- Changed realpath cache to be disabled when "open_basedir" or "safe_mode"
View
16 main/php_ini.c
@@ -310,6 +310,14 @@ int php_init_config(TSRMLS_D)
free_ini_search_path = 1;
php_ini_search_path[0] = 0;
+ /* Add environment location */
+ if (env_location[0]) {
+ if (*php_ini_search_path) {
+ strcat(php_ini_search_path, paths_separator);
+ }
+ strcat(php_ini_search_path, env_location);
+ }
+
#ifdef PHP_WIN32
/* Add registry location */
reg_location = GetIniPathFromRegistry();
@@ -322,14 +330,6 @@ int php_init_config(TSRMLS_D)
}
#endif
- /* Add environment location */
- if (env_location[0]) {
- if (*php_ini_search_path) {
- strcat(php_ini_search_path, paths_separator);
- }
- strcat(php_ini_search_path, env_location);
- }
-
/* Add cwd (only with CLI) */
if (strcmp(sapi_module.name, "cli") == 0) {
if (*php_ini_search_path) {

0 comments on commit acb1e07

Please sign in to comment.