[whatwg] Zip archives as first-class citizens

Glenn Maynard glenn at zewt.org
Wed Aug 28 10:21:55 PDT 2013


On Wed, Aug 28, 2013 at 12:07 PM, Eric Uhrhane <ericu at chromium.org> wrote:

> We've covered this several times.  The directory records in a zip can
> be superseded by further directories later in the archive, so you
> can't trust that you've got the right directory until you're done
> downloading.
>

Both the local headers and the central record can be wrong.  (As mentioned
on IRC the other day, apparently EPUB files often have broken central
records, so eBook readers probably prefer the local records.)  If they're
out of sync, then they'll always be broken in some clients.

We just have to make sure that the record that takes priority in any
particular case is well-defined, so we have interop.  If some malformed
archives won't work in some cases as a result, using a different format
isn't an improvement: that just means *zero* existing archives would work.

This applies to various other aspects of the format: the maximum supported
length of comments and handling of duplicate filenames, for example.  This
would all need to be specified; the ZIP "AppNote" doesn't specify a parser
or error handling in the way the web needs, it just describes the format.

-- 
Glenn Maynard



More information about the whatwg mailing list