summaryrefslogtreecommitdiff
path: root/win32
diff options
context:
space:
mode:
authoreban <eban@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2003-11-27 09:13:50 +0000
committereban <eban@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2003-11-27 09:13:50 +0000
commit66598727efaf03a47cad36a4884632574cd9d331 (patch)
tree6b97e064bb46c38c44605b45481cda98409e7075 /win32
parent1dd762d181d1be653772653f7121655ad9e50046 (diff)
win32/win32.c (rb_win32_stat): add "." to buf1 only if it has a drive letter.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@5038 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
Diffstat (limited to 'win32')
-rw-r--r--win32/win32.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/win32/win32.c b/win32/win32.c
index 6a7f6be9b8..966c326466 100644
--- a/win32/win32.c
+++ b/win32/win32.c
@@ -2734,7 +2734,7 @@ rb_w32_stat(const char *path, struct stat *st)
*end = '\0';
else if (*end != '\\')
strcat(buf1, "\\");
- } else if (*end == '\\' || *end == ':')
+ } else if (*end == '\\' || (buf1 + 1 == end && *end == ':'))
strcat(buf1, ".");
ret = stat(buf1, st);