diff options
author | nobu <nobu@b2dd03c8-39d4-4d8f-98ff-823fe69b080e> | 2003-01-29 23:28:47 +0000 |
---|---|---|
committer | nobu <nobu@b2dd03c8-39d4-4d8f-98ff-823fe69b080e> | 2003-01-29 23:28:47 +0000 |
commit | b18b4423c9f21f06bfdc13c2430582722981338e (patch) | |
tree | 5582a1580f62cc35a0ea79b2fbb712b33593e12f /file.c | |
parent | 79862de36334225179ee4e462ccb982ea5250800 (diff) | |
download | ruby-b18b4423c9f21f06bfdc13c2430582722981338e.tar.gz |
* file.c (rb_file_s_expand_path): removed a sludge.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@3420 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
Diffstat (limited to 'file.c')
-rw-r--r-- | file.c | 7 |
1 files changed, 5 insertions, 2 deletions
@@ -1464,12 +1464,15 @@ rb_file_s_expand_path(argc, argv) } BUFCHECK(strlen(dir) > buflen); strcpy(buf, dir); - for (p = buf; p < buf + strlen(dir); p = CharNext(p)) { - if (isdirsep(*p)) { +#ifdef DOSISH + for (p = buf; *p; p = CharNext(p)) { + if (*p == '\\') { *p = '/'; } } +#else p = buf + strlen(dir); +#endif s++; tainted = 1; } |