Skip to content

Clearing the general purpose flag  #440

@wuanne15

Description

@wuanne15

Hi!
I’ve been working on moving my code from version 1.1 of mini zip to version 2.8.9, but I’ve been encountering some issues. Currently my code reads the length of a file from the file header. The problem is that the local header file in the zip file no longer has the uncompressed size of the file, but instead the file descriptor contains it. I read in appnotes.txt that if the 3rd bit of the general purpose flags is set then the CRC-32 and uncompressed size fields are set to be zero in the local header and the correct values are put in the data descriptor and central directory. I checked the hexdump of the newly generated zip file, and the 3rd bit of the general purpose flag is indeed set. Thus I was wondering how I can disable this so that the uncompressed file size and crc-32 data are contained in the local header file instead of the data descriptors.

I'm using the function zipWriteInFileInZip.

Thanks so much!

Metadata

Metadata

Assignees

No one assigned

    Labels

    fixedIssue or bug has been fixednew featureNew feature

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions