Uploaded image for project: 'JDK'
  1. JDK
  2. JDK-8336529

(fs) UnixFileAttributeViews setTimes() failing on armhf, Ubuntu noble

XMLWordPrintable

    • Icon: Bug Bug
    • Resolution: Fixed
    • Icon: P4 P4
    • 24
    • 17, 21, 22, 23, 24
    • core-libs
    • None
    • b12
    • arm
    • linux_ubuntu

      The issue is caused by 64 bit time_t transition.

      Multiple jtreg tests fail in Ubuntu noble, armhf because they assert the file modification time:

      jdk/nio/zipfs/CopyMoveTests.java
      jdk/nio/zipfs/TestPosix.java
      java/nio/file/attribute/BasicFileAttributeView/Basic.java
      java/nio/file/attribute/BasicFileAttributeView/CreationTime.java
      java/nio/file/Files/SetLastModifiedTime.java
      java/nio/file/Files/SymlinkTime.java
      tools/javac/modules/MOptionTest.java

      runtime/cds/appcds/dynamicArchive/DynamicSharedSymbols.java
      runtime/cds/appcds/jcmd/JCmdTestDynamicDump.java
      runtime/cds/appcds/jcmd/JCmdTestFileSafety.java
      runtime/cds/appcds/jcmd/JCmdTestStaticDump.java
      runtime/cds/appcds/RelativePath.java
      runtime/jcmd/JcmdCmdLine.java
      serviceability/attach/AttachNegativePidTest.java
      serviceability/attach/RemovingUnixDomainSocketTest.java
      serviceability/HeapDump/DuplicateArrayClassesTest.java
      serviceability/HeapDump/FieldsInInstanceTest.java

      The file modification time is set in sun.nio.fs.UnixFileAttributeViews.setTimes() method, that calls
      Java_sun_nio_fs_UnixNativeDispatcher_futimens0 in 'src/java.base/unix/native/libnio/fs/UnixNativeDispatcher.c'.

      The function pointer my_futimens_func has the version of the function that assumes 32 bit time_t, causing the failure to set last modification time.


            vpetko Vladimir Petko
            vpetko Vladimir Petko
            Votes:
            0 Vote for this issue
            Watchers:
            5 Start watching this issue

              Created:
              Updated:
              Resolved: