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

ZipEntry getComment returns null when using ZipInputStream to read ZIP file

XMLWordPrintable

    • Icon: Bug Bug
    • Resolution: Not an Issue
    • Icon: P4 P4
    • None
    • 1.1.7
    • tools
    • None
    • jar
    • sparc
    • solaris_2.6

      java.util.zip ZipEntry getComment returns null when ZipInputStream is used
      to read the ZIP file. All the other properties (name, compressed size, crc,
      extra, size, time, method) have the correct information.

      Used ZIP files that were compressed and uncompressed. When creating the ZIP
      files the Zip entry properties were set before the data was written, so this
      information would be before the actual data. So all the information is in the
      Zip entry when ZipInputStream.getNextEntry is used.

      Note: When using ZipFile to read from the ZIP file, getComment returns the
      correct comment.

      Test program below:

            zlisunw Zhenghua Li (Inactive)
            mcolburnsunw Michael Colburn (Inactive)
            Votes:
            0 Vote for this issue
            Watchers:
            0 Start watching this issue

              Created:
              Updated:
              Resolved:
              Imported:
              Indexed: