diff options
Diffstat (limited to 'ext/standard/string.c')
-rw-r--r-- | ext/standard/string.c | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/ext/standard/string.c b/ext/standard/string.c index a866d9c5ad..9a3dacc7a9 100644 --- a/ext/standard/string.c +++ b/ext/standard/string.c @@ -471,14 +471,14 @@ PHP_FUNCTION(basename) ret = estrdup((*str)->value.str.val); c = ret + (*str)->value.str.len -1; while (*c == '/' -#if PHP_WIN32 +#ifdef PHP_WIN32 || *c == '\\' #endif ) c--; *(c + 1) = '\0'; if ((c = strrchr(ret, '/')) -#if PHP_WIN32 +#ifdef PHP_WIN32 || (c = strrchr(ret, '\\')) #endif ) { @@ -495,14 +495,14 @@ PHPAPI void php_dirname(char *str, int len) { c = str + len - 1; while (*c == '/' -#if PHP_WIN32 +#ifdef PHP_WIN32 || *c == '\\' #endif ) c--; /* strip trailing slashes */ *(c + 1) = '\0'; if ((c = strrchr(str, '/')) -#if PHP_WIN32 +#ifdef PHP_WIN32 || (c = strrchr(str, '\\')) #endif ) |