summaryrefslogtreecommitdiff
path: root/TSRM/tsrm_virtual_cwd.h
diff options
context:
space:
mode:
authorRui Hirokawa <hirokawa@php.net>2002-04-25 14:43:40 +0000
committerRui Hirokawa <hirokawa@php.net>2002-04-25 14:43:40 +0000
commit860e67588461bd93108ab48dd7d8459df6d96a5c (patch)
tree349e22e6510935e932e4b90de03fff49b9fee642 /TSRM/tsrm_virtual_cwd.h
parent03a52cd97c20eb46a1d2383ab2d49c32be242e4e (diff)
downloadphp-git-860e67588461bd93108ab48dd7d8459df6d96a5c.tar.gz
fixed directory access problem when direcory name is encoded in japanese Shift_JIS encoding.
Diffstat (limited to 'TSRM/tsrm_virtual_cwd.h')
-rw-r--r--TSRM/tsrm_virtual_cwd.h3
1 files changed, 3 insertions, 0 deletions
diff --git a/TSRM/tsrm_virtual_cwd.h b/TSRM/tsrm_virtual_cwd.h
index 52afebe0da..98efaa1432 100644
--- a/TSRM/tsrm_virtual_cwd.h
+++ b/TSRM/tsrm_virtual_cwd.h
@@ -50,6 +50,8 @@ typedef unsigned short mode_t;
#define DEFAULT_SLASH '\\'
#define DEFAULT_DIR_SEPARATOR ';'
#define IS_SLASH(c) ((c) == '/' || (c) == '\\')
+#define IS_SLASH_P(c) (*(c) == '/' || \
+ (*(c) == '\\' && !IsDBCSLeadByte(*(c-1))))
#define COPY_WHEN_ABSOLUTE 2
#define IS_ABSOLUTE_PATH(path, len) \
(len >= 2 && isalpha(path[0]) && path[1] == ':')
@@ -70,6 +72,7 @@ typedef unsigned short mode_t;
#endif
#define IS_SLASH(c) ((c) == '/')
+#define IS_SLASH_P(c) (*(c) == '/')
#endif