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

Add ability to set File Attributes on Zip Entries

XMLWordPrintable

    • Icon: Enhancement Enhancement
    • Resolution: Unresolved
    • Icon: P4 P4
    • None
    • 6u5
    • core-libs
    • Cause Known
    • x86
    • windows_xp

      J2SE Version (please include all output from java -version flag):
      java version "1.6.0_05"
      Java(TM) SE Runtime Environment (build 1.6.0_05-b13)
      Java HotSpot(TM) Client VM (build 10.0-b19, mixed mode, sharing)

      Does this problem occur on J2SE 5.0.x or 6.0? Yes / No (pick one)
      Yes

      Operating System Configuration Information (be specific):
      Microsoft Windows XP [Version 5.1.2600]

      Bug Description:
      RFE: Add ability to set File Attributes on Zip Entries

      Inside ZipOutputStream there is already a note: 'REMIND: add support for file attributes'
      so it looks like there are already plans to do this

      The writeCEN method already contains the line writeInt(0); // external file attributes (unused)
      All we need are method to set/get the File Attributes on a Zip Entry and for this
      writeInt to be changed to write that value instead of 0.

      I suggest adding methods allowing for any int value, and possibly later on adding
      additional convenience methods to set the file attributes for known platforms as
      documented in http://www.pkware.com/documents/casestudies/APPNOTE.TXT)

            sherman Xueming Shen
            tyao Ting-Yun Ingrid Yao (Inactive)
            Votes:
            0 Vote for this issue
            Watchers:
            0 Start watching this issue

              Created:
              Updated:
              Imported:
              Indexed: