diff options
Diffstat (limited to 'libjava/java/io')
-rw-r--r-- | libjava/java/io/File.java | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/libjava/java/io/File.java b/libjava/java/io/File.java index a268278..2086f10 100644 --- a/libjava/java/io/File.java +++ b/libjava/java/io/File.java @@ -82,6 +82,11 @@ public class File implements Serializable, Comparable // Remove duplicate and redundant separator characters. private String normalizePath(String p) { + // On Windows, convert any '/' to '\'. This appears to be the same logic + // that Sun's Win32 Java performs. + if (separatorChar == '\\') + p = p.replace ('/', '\\'); + int dupIndex = p.indexOf(dupSeparator); int plen = p.length(); |