[BusyBox] Re: [PATCH] Re: Sigh... this time i attached the file (bunzip-4.c)
rob at landley.net
Thu Oct 23 05:34:06 UTC 2003
On Wednesday 22 October 2003 17:12, Glenn McGrath wrote:
> On Wed, 22 Oct 2003 09:57:35 -0600
> mjn3 at codepoet.org (Manuel Novoa III) wrote:
> > Of course, the analogy with read() does break down in another respect.
> > Because read_bunzip() can read and buffer more than it needs, you
> > might have unused data remaining in the bunzip buffer if there is data
> > trailing the compressed block. That is definitely an issue if you
> > want to treat this as a "black box".
> This is an issue i have run into with the dpkg and dpkg-deb applets, in
> .deb's there are two .tar.gz inside an ar archive, if you read too much
> much for the first tar.gz youve read past next ar header, and possibly
> into the next .tar.gz.
> (busybox supports .tar.bz2 inside deb's buts its non-standard)
> hmm, i need to do some testing to verify its current behaviour.
When reading from a filehandle, we can easily figure out how much we overshot
and lseek backwards a bit. The only question is should this be in the
gzip/bzip library code, or in the code that calls it?
More information about the busybox