summaryrefslogtreecommitdiff
path: root/ext
diff options
context:
space:
mode:
authorSterling Hughes <sterling@php.net>2002-09-11 22:40:56 +0000
committerSterling Hughes <sterling@php.net>2002-09-11 22:40:56 +0000
commitb34bec20a7b83b67c8506e5c8a1bdd16d6fec665 (patch)
tree75e05d8dc1f38685e65fab0bbd3074be128bda31 /ext
parentc57b3c653354a62c4146d62a3e4a8005b6a68e8f (diff)
downloadphp-git-b34bec20a7b83b67c8506e5c8a1bdd16d6fec665.tar.gz
max this use the virtual_filepath() function and feel all threadsafe and
wholesome inside
Diffstat (limited to 'ext')
-rw-r--r--ext/standard/filestat.c13
1 files changed, 13 insertions, 0 deletions
diff --git a/ext/standard/filestat.c b/ext/standard/filestat.c
index 4195aa0f8e..85b28bfe9f 100644
--- a/ext/standard/filestat.c
+++ b/ext/standard/filestat.c
@@ -570,6 +570,19 @@ static void php_stat(const char *filename, php_stat_len filename_length, int typ
}
#ifndef PHP_WIN32
+#if VIRTUAL_DIR
+ do {
+ char *tmpname;
+
+ if (virtual_filepath(filename, &tmpname TSRMLS_CC)) {
+ php_error(E_WARNING, "Cannot get the virtual filepath of %s\n", filename);
+ RETURN_FALSE;
+ }
+
+ filename = tmpname;
+ } while (0);
+#endif
+
switch (type) {
case FS_IS_W:
RETURN_BOOL (!access (filename, W_OK));