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

ZipEntry related JCK conformance test is failing in JDK23

XMLWordPrintable

    • Icon: Bug Bug
    • Resolution: Not an Issue
    • Icon: P3 P3
    • None
    • 23
    • core-libs

      Observed the test failure in JDK23, likely caused by JDK-8316141.

      The test is validating the ZipEntry::setComment method

      https://download.java.net/java/early_access/jdk23/docs/api/java.base/java/util/zip/ZipEntry.html#setComment(java.lang.String)

      "ZIP entry comments have maximum length of 0xffff. If the length of the specified comment string is greater than 0xFFFF bytes after encoding, only the first 0xFFFF bytes are output to the ZIP file entry."

      Here the test is providing the comment length up to or beyond 0xFFFF to validate the stated spec.

      I see the test failing after JDK-8316141 integration which is doing the strict CEN header validation.

      It looks to me a regression , until unless we have a specification supporting the strict validation of the CEN header

      Attaching standalone code which is a simple version of the actual test failing (JCK-7320039)

      The sample attached works fine < JDK23 fails in JDK23

        1. TestZipEntryComment.java
          1 kB
          Krushnareddy Ganapureddy

            lancea Lance Andersen
            kganapureddy Krushnareddy Ganapureddy
            Votes:
            0 Vote for this issue
            Watchers:
            5 Start watching this issue

              Created:
              Updated:
              Resolved: