Ashay Rane 1d36647ba1
Handle ERROR_NOT_SUPPORTED from GetFileInformationByName()
Even if the `GetFileInformationByName()` API is supported by the OS, the
API may return with the error `ERROR_NOT_SUPPORTED` for certain
endpoints like OneDrive folders mounted on SMB.  Prior to this patch,
this caused the call to read filesystem attributes to terminate with the
`java.nio.file.FileSystemException` ("The request is not supported").

This patch fixes the problem so that when `GetFileInformationByName()`
fails with `ERROR_NOT_SUPPORTED`, then we drop to the slow path (opening
the file handle, calling `GetFileInformationByHandle()`, followed by
closing the file handle.

Reproducing this problem requires both OneDrive folders and SMB shares,
so (as far as I am aware) it's not possible to recreate the environment
in a test.
2026-07-31 14:35:07 -05:00
2026-06-22 11:46:03 +00:00
2016-05-30 16:17:11 +02:00
2024-09-25 16:25:23 +00:00

Welcome to the JDK!

For build instructions please see the online documentation, or either of these files:

See https://openjdk.org/ for more information about the OpenJDK Community and the JDK and see https://bugs.openjdk.org for JDK issue tracking.

Languages
Java 73.9%
C++ 14.3%
C 7.8%
Assembly 2.7%
Objective-C 0.4%
Other 0.7%