diff options
author | Pierre Joye <pierre.php@gmail.com> | 2013-01-08 15:06:58 +0100 |
---|---|---|
committer | Pierre Joye <pierre.php@gmail.com> | 2013-01-08 15:06:58 +0100 |
commit | 2fb7cd30c59345838588ba89ad8b05cc4c34d6dd (patch) | |
tree | 2ea5e8bc652c8cc0246fed62af59e0edcc1e5bf0 | |
parent | a71e91626a3a72d360c285d0c78a16dbac6a0840 (diff) | |
parent | 50ceeb9f750cecedc483ffc3d3e65a3324e21866 (diff) | |
download | php-git-2fb7cd30c59345838588ba89ad8b05cc4c34d6dd.tar.gz |
- fix bug #47358, glob returns error, should be empty array()
-rw-r--r-- | ext/standard/dir.c | 4 |
1 files changed, 1 insertions, 3 deletions
diff --git a/ext/standard/dir.c b/ext/standard/dir.c index d921f7c3f5..91d1e049d5 100644 --- a/ext/standard/dir.c +++ b/ext/standard/dir.c @@ -492,9 +492,7 @@ PHP_FUNCTION(glob) if (!globbuf.gl_pathc || !globbuf.gl_pathv) { no_results: if (PG(open_basedir) && *PG(open_basedir)) { - struct stat s; - - if (0 != VCWD_STAT(pattern, &s) || S_IFDIR != (s.st_mode & S_IFMT)) { + if (php_check_open_basedir_ex(pattern, 0 TSRMLS_CC)) { RETURN_FALSE; } } |