zlib: wrap deflateBound() too

Signed-off-by: Junio C Hamano <gitster@pobox.com>
This commit is contained in:
Junio C Hamano
2011-06-10 11:18:17 -07:00
parent 55bb5c9147
commit 225a6f1068
8 changed files with 17 additions and 10 deletions

View File

@ -476,7 +476,7 @@ static int post_rpc(struct rpc_state *rpc)
memset(&stream, 0, sizeof(stream));
git_deflate_init_gzip(&stream, Z_BEST_COMPRESSION);
size = deflateBound(&stream, rpc->len);
size = git_deflate_bound(&stream, rpc->len);
gzip_body = xmalloc(size);
stream.next_in = (unsigned char *)rpc->buf;