RFR: 8343823: (fs) Files.createLink: inconsistent behavior when creating link to symbolic link

Brian Burkhalter bpb at openjdk.org
Tue Nov 19 21:39:26 UTC 2024


On Tue, 19 Nov 2024 21:33:42 GMT, Brian Burkhalter <bpb at openjdk.org> wrote:

> Add an API note to `java.nio.file.Files.createLink` to make explicit that the behavior when the target is a symbolic link is unspecified.

The behavior cannot be made specifiable without a backward incompatible change. A similar method with specifiable behavior could be added, for example:

`File.createHardLink(Path link, Path existing, LinkOption... options)`.

-------------

PR Comment: https://git.openjdk.org/jdk/pull/22257#issuecomment-2486799191


More information about the nio-dev mailing list