Thread (25 messages) flat view 25 messages, 3 authors, 2007-07-19

Re: [PATCH 3/15] boot: simplfy gunzip_finish

From: David Gibson <hidden>
Date: 2007-07-19 02:39:17

On Tue, Jul 10, 2007 at 05:08:32PM -0500, Milton Miller wrote:
Call gunzip_partial to calculate the remaining length and copy the
data to the user buffer.   This makes it shorter and reduces
duplication.

Signed-off-by: Milton Miller <redacted>
Hrm... I guess this is sufficient.  Since we'll shortly be blowing
away the state anyway, the lack of call to inflateEnd doesn't really
matter.  Originally I was going to make this function call fatal() if
the destination didn't have enough space to contain the decompressed
tail of the image, but obviously I decided aginst that.

But, if you're going to do this, you might as well get rid of
gunzip_finish() entirely, and have the callers using gunzip_partial
instead.

-- 
David Gibson			| I'll have my music baroque, and my code
david AT gibson.dropbear.id.au	| minimalist, thank you.  NOT _the_ _other_
				| _way_ _around_!
http://www.ozlabs.org/~dgibson
Keyboard shortcuts
hback out one level
jnext message in thread
kprevious message in thread
ldrill in
Escclose help / fold thread tree
?toggle this help