A DESCRIPTION OF THE PROBLEM :
I noticed that the underlying os file stat library function in hotspot follows symlinks on POSIX platforms (because it simply calls stat(2)) but not on Windows (because GetFileAttributesExW does not follow symlinks). This may cause inconsistencies between Windows and other platforms with regard to symlinks.
One I ran into is that if you put a directory on the boot class path, class files within the directory may be symlinks on POSIX platforms but not Windows. This is because ClassPathDirEntry::open_stream assumes the size it gets back from os::stat is the size of the file it will read with os::open.
I noticed that the underlying os file stat library function in hotspot follows symlinks on POSIX platforms (because it simply calls stat(2)) but not on Windows (because GetFileAttributesExW does not follow symlinks). This may cause inconsistencies between Windows and other platforms with regard to symlinks.
One I ran into is that if you put a directory on the boot class path, class files within the directory may be symlinks on POSIX platforms but not Windows. This is because ClassPathDirEntry::open_stream assumes the size it gets back from os::stat is the size of the file it will read with os::open.