RFR: 8154364: Files.isSameFile() throws NoSuchFileException with broken symbolic links [v2]
Alan Bateman
alanb at openjdk.org
Thu Aug 14 16:44:11 UTC 2025
On Thu, 14 Aug 2025 16:37:51 GMT, Brian Burkhalter <bpb at openjdk.org> wrote:
>> For some reason TBD, `UnixFileAttributes.get` succeeds with a symlink loop but `UnixFileAttributes.getIfExists` fails with `ELOOP`.
>
> The `ELOOP` apparently is from the `stat` syscall and does not occur in the current version because `access` is called before `stat` and does not fail in that way. So I am not sure that `getIfExists` is the way to go here unless we want to punt the link loop cases.
Are you testing a loop in the file system?
-------------
PR Review Comment: https://git.openjdk.org/jdk/pull/26736#discussion_r2277146480
More information about the nio-dev
mailing list