]> git.ipfire.org Git - thirdparty/git.git/commit - zlib.c
zlib: allow feeding more than 4GB in one go
authorJunio C Hamano <gitster@pobox.com>
Fri, 10 Jun 2011 19:15:17 +0000 (12:15 -0700)
committerJunio C Hamano <gitster@pobox.com>
Fri, 10 Jun 2011 23:17:19 +0000 (16:17 -0700)
commite01503b523e79748ac91d876f506811c597d03cb
tree5d5d0cab5583849244fa903ce79ac8ec6b242a7f
parentef49a7a0126d64359c974b4b3b71d7ad42ee3bca
zlib: allow feeding more than 4GB in one go

Update zlib_post_call() that adjusts the wrapper's notion of avail_in and
avail_out to what came back from zlib, so that the callers can feed
buffers larger than than 4GB to the API.

When underlying inflate/deflate stopped processing because we fed a buffer
larger than 4GB limit, detect that case, update the state variables, and
let the zlib function work another round.

Signed-off-by: Junio C Hamano <gitster@pobox.com>
zlib.c