summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorRasmus Lerdorf <rasmus@php.net>2002-09-28 16:27:53 +0000
committerRasmus Lerdorf <rasmus@php.net>2002-09-28 16:27:53 +0000
commita12abe498e134a3dfcbe09423f7ce5e985a68148 (patch)
tree963698937fd963397249a99984b4bbb2bb9eae14
parent48bbd2879b76049352cd87990b4e70101f321fa8 (diff)
downloadphp-git-a12abe498e134a3dfcbe09423f7ce5e985a68148.tar.gz
MFH fix for bug 19292
-rw-r--r--main/fopen_wrappers.c6
1 files changed, 3 insertions, 3 deletions
diff --git a/main/fopen_wrappers.c b/main/fopen_wrappers.c
index 89501b3132..a71669aec9 100644
--- a/main/fopen_wrappers.c
+++ b/main/fopen_wrappers.c
@@ -226,8 +226,8 @@ PHPAPI int php_check_open_basedir(const char *path TSRMLS_DC)
PHPAPI int php_check_safe_mode_include_dir(char *path TSRMLS_DC)
{
/* Only check when safe_mode on and safe_mode_include_dir is available */
- if (PG(safe_mode) && PG(safe_mode_include_dir) &&
- *PG(safe_mode_include_dir))
+ if (((PG(open_basedir) && *PG(open_basedir)) || PG(safe_mode))
+ && PG(safe_mode_include_dir) && *PG(safe_mode_include_dir))
{
char *pathbuf;
char *ptr;
@@ -268,7 +268,7 @@ PHPAPI int php_check_safe_mode_include_dir(char *path TSRMLS_DC)
}
/* Nothing to check... */
- return -1;
+ return 0;
}
/* }}} */