Re: [PATCH v3 4/5] archive-zip: support archives bigger than 4GB
- From
Peter Krefting <peter@softwolves.pp.se>
- Date
- Apr 28, 2017, 08:40 UTC
- Message-ID
- <alpine.DEB.2.00.1704280936290.1440@ds9.cixit.se>
- In-Reply-To
- <a9cb6572-500e-bbc6-2aac-7cb940d4b171@web.de>
René Scharfe:
> Sure, but if we were to start emitting zip64 records regardless of > the size of entries then we'd break compatibility. We should have a > very good reason for doing that. (I don't see the need so far.)
Sure, sounds good.
> The type of descriptor to use depends on the presence of 64-bit > sizes in a zip64 extra for that record. For streaming compression > some kind of threshold lower than 0xffffffff needs to be set, > because deflate can increase the size of the result.
Indeed. And it seems that they use the version identifier (>= 45) to check whether it is in "zip64 format" or not. It seems a bit hit or miss to me, the best would be to always use the pre-amble descriptor, but that requires holding the entire compressed data in memory (or using temporary files or running two passes), neither which are very good ideas.
-- \\// Peter - http://www.softwolves.pp.se/