IBM Support

IV59352: JAVA.UTIL.ZIP.ZIPEXCEPTION IS THROWN WHEN COPYING JAR FILE USING PACK200 API

Subscribe

You can track all active APARs for this component.

 

APAR status

  • Closed as program error.

Error description

  • Error Message: ZipException is thrown when copying JAR file
    using Pack200 API
    .
    Stack Trace: java.util.zip.ZipException: invalid entry
    compressed size (expected 2 but got 3 bytes)at
    java.util.zip.ZipOutputStream.closeEntry(ZipOutputStream.java:24
    8)at
    java.util.zip.ZipOutputStream.putNextEntry(ZipOutputStream.java:
    177)at
    java.util.jar.JarOutputStream.putNextEntry(JarOutputStream.java:
    109)at
    com.sun.java.util.jar.pack.Utils.copyJarFile(Utils.java:258)at
    com.sun.java.util.jar.pack.Utils.copyJarFile(Utils.java:281)at
    com.sun.java.util.jar.pack.PackerImpl.pack(PackerImpl.java:97)..
    .Suppressed: java.util.zip.ZipException: invalid entry
    compressed size (expected 2 but got 3 bytes)at
    java.util.zip.ZipOutputStream.closeEntry(ZipOutputStream.java:24
    8)at
    java.util.zip.ZipOutputStream.finish(ZipOutputStream.java:343)at
    java.util.zip.DeflaterOutputStream.close(DeflaterOutputStream.ja
    va:238)at
    java.util.zip.ZipOutputStream.close(ZipOutputStream.java:360)at
    com.sun.java.util.jar.pack.Utils.copyJarFile(Utils.java:282)...
    2 more
    .
    

Local fix

Problem summary

  • When a JAR file generated using one compression algorithm is
    copied to another JAR file using a different compression
    algorithm, the compressed sizes of entries stored in the input
    JAR file may not match with the compressed size generated for
    entries in the output JAR file.  This is because different
    versions of compression algorithms can generate different
    compressed sizes.  Hence, we get the "ZipException: invalid
    entry compressed size".
    

Problem conclusion

  • This APAR will be fixed in the following Java Releases:
       7    SR7       (7.0.7.0)
       7 R1 SR1       (7.1.1.0)
    .
    The Pack200 API is modified to ensure that the JAR entry in the
    output JAR file is updated with the newly computed compressed
    size instead of using the JAR entry value read from the input
    JAR file.
    

Temporary fix

Comments

APAR Information

  • APAR number

    IV59352

  • Reported component name

    JAVA CLASS LIBS

  • Reported component ID

    620700130

  • Reported release

    700

  • Status

    CLOSED PER

  • PE

    NoPE

  • HIPER

    NoHIPER

  • Special Attention

    NoSpecatt

  • Submitted date

    2014-04-16

  • Closed date

    2014-04-16

  • Last modified date

    2014-04-16

  • APAR is sysrouted FROM one or more of the following:

  • APAR is sysrouted TO one or more of the following:

Fix information

  • Fixed component name

    JAVA CLASS LIBS

  • Fixed component ID

    620700130

Applicable component levels

  • R700 PSY

       UP

[{"Business Unit":{"code":"BU059","label":"IBM Software w\/o TPS"},"Product":{"code":"SSNVBF","label":"Runtimes for Java Technology"},"Platform":[{"code":"PF025","label":"Platform Independent"}],"Version":"7.0","Line of Business":{"code":"LOB36","label":"IBM Automation"}}]

Document Information

Modified date:
22 February 2022