-
Enhancement
-
Resolution: Fixed
-
P3
-
7u9
-
Windows 7, JDK 1.7
-
b15
-
generic
-
windows
Steps to reproduce:
Create a symlink on MS Windows (NTFS file system):
F:\> mkdir link-target
F:\> mklink /D link f:\link-target
symbolic link created for link <<===>> f:\link-target
Run this Java code:
public static void main(String[] args) throws IOException {
File file = new File("f:\\link");
System.out.println(file);
System.out.println(file.getCanonicalFile());
System.out.println(file.getCanonicalFile().getCanonicalFile());
}
The result is:
f:\link
F:\link
F:\link
See also this NetBeans issue: http://netbeans.org/bugzilla/show_bug.cgi?id=222158
Create a symlink on MS Windows (NTFS file system):
F:\> mkdir link-target
F:\> mklink /D link f:\link-target
symbolic link created for link <<===>> f:\link-target
Run this Java code:
public static void main(String[] args) throws IOException {
File file = new File("f:\\link");
System.out.println(file);
System.out.println(file.getCanonicalFile());
System.out.println(file.getCanonicalFile().getCanonicalFile());
}
The result is:
f:\link
F:\link
F:\link
See also this NetBeans issue: http://netbeans.org/bugzilla/show_bug.cgi?id=222158
- relates to
-
JDK-8348900 Regressions 8 and 16% on pmd and luindex on Windows
-
- Open
-
-
JDK-8349006 File.getCanonicalPath should remove "(on UNIX platforms)" from its specification
-
- Resolved
-
-
JDK-8022671 Revisit the Logic of Handling Devices In Java IO/NIO Functions
-
- Open
-
-
JDK-8348828 Windows dll loading now resolves symlinks
-
- Open
-
- links to
-
Commit(master) openjdk/jdk/042053c3
-
Review(master) openjdk/jdk/20801
(1 links to)