RFR: 8341282: (fs) Move creation time fallback logic to Java layer (Linux) [v3]

Alan Bateman alanb at openjdk.org
Wed Oct 2 13:51:39 UTC 2024


On Tue, 1 Oct 2024 19:57:52 GMT, Brian Burkhalter <bpb at openjdk.org> wrote:

>> Move the decision as to whether `BasicFileAttributes.creationTime()` falls back to the modified time from the native layer to the Java layer.
>
> Brian Burkhalter has updated the pull request incrementally with one additional commit since the last revision:
> 
>   8341282: Unset birthtime_available when using stat(2) on Linux

src/java.base/unix/classes/sun/nio/fs/UnixFileAttributes.java line 61:

> 59:     private long    st_birthtime_sec;
> 60:     private long    st_birthtime_nsec;
> 61:     private boolean birthtime_available = true;

I have a mild preference to leave the default be false, then set it to true in the native code when setting the birth time.

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

PR Review Comment: https://git.openjdk.org/jdk/pull/21274#discussion_r1784565290


More information about the nio-dev mailing list