see also http://bugs.php.net/bug.php?id=34793 --- php-4.4.2/main/php_ini.c~ 2006-01-17 19:02:09.000000000 +0200 +++ php-4.4.2/main/php_ini.c 2006-01-17 19:26:46.000000000 +0200 @@ -19,7 +19,7 @@ /* $Id$ */ /* Check CWD for php.ini */ -#define INI_CHECK_CWD +#undef INI_CHECK_CWD #include "php.h" #include "ext/standard/info.h" @@ -328,13 +327,13 @@ efree(binary_location); binary_location = NULL; } -#else + if (sapi_module.executable_location) { binary_location = estrdup(sapi_module.executable_location); } else { binary_location = NULL; } -#endif + if (binary_location) { char *separator_location = strrchr(binary_location, DEFAULT_SLASH); @@ -349,7 +348,6 @@ } /* Add default location */ -#ifdef PHP_WIN32 default_location = (char *) emalloc(MAXPATHLEN + 1); if (0 < GetWindowsDirectory(default_location, MAXPATHLEN)) {