Patch: Short read problem in unzip and gunzip

JoSH Lehan krellan at gmail.com
Mon Jan 28 04:17:44 UTC 2008


Thanks for responding.

> Failing that, at least give a reproducible testcase -
> how do you force short reads?
> (no promices that I can work on it soon, though... sorry).

To give unzip a short read, have it decompress data that comes in
through a pipe.

cat myfile.zip | unzip -

This should quickly reproduce the problem.  As a worst case scenario,
let unzip only have one byte at a time.

cat myfile.zip | dd bs=1 | unzip -

The zipfile you're decompressing should have multiple files in it.
Only the first file will work.  The remaining files should fail with
an error.

Josh



More information about the busybox mailing list