diff options
author | Junio C Hamano <gitster@pobox.com> | 2009-01-21 16:55:17 -0800 |
---|---|---|
committer | Junio C Hamano <gitster@pobox.com> | 2009-01-21 16:55:17 -0800 |
commit | 36dd9393938d4e7f8843c6c587c9b4db077377fc (patch) | |
tree | 068987295f97b419452a69d3c15b82882a9e1582 /http-push.c | |
parent | 664a3348b22bd5fe5d2d97b9985edeaf3a34cb71 (diff) | |
parent | 39c68542fc8d8477f2080c99efedb9dce975abc6 (diff) | |
download | git-36dd9393938d4e7f8843c6c587c9b4db077377fc.tar.gz git-36dd9393938d4e7f8843c6c587c9b4db077377fc.tar.xz |
Merge branch 'lt/maint-wrap-zlib'
* lt/maint-wrap-zlib:
Wrap inflate and other zlib routines for better error reporting
Conflicts:
http-push.c
http-walker.c
sha1_file.c
Diffstat (limited to 'http-push.c')
-rw-r--r-- | http-push.c | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/http-push.c b/http-push.c index 6ad853e2d..cb5bf95a7 100644 --- a/http-push.c +++ b/http-push.c @@ -209,7 +209,7 @@ static size_t fwrite_sha1_file(void *ptr, size_t eltsize, size_t nmemb, do { request->stream.next_out = expn; request->stream.avail_out = sizeof(expn); - request->zret = inflate(&request->stream, Z_SYNC_FLUSH); + request->zret = git_inflate(&request->stream, Z_SYNC_FLUSH); git_SHA1_Update(&request->c, expn, sizeof(expn) - request->stream.avail_out); } while (request->stream.avail_in && request->zret == Z_OK); @@ -269,7 +269,7 @@ static void start_fetch_loose(struct transfer_request *request) memset(&request->stream, 0, sizeof(request->stream)); - inflateInit(&request->stream); + git_inflate_init(&request->stream); git_SHA1_Init(&request->c); @@ -310,7 +310,7 @@ static void start_fetch_loose(struct transfer_request *request) file; also rewind to the beginning of the local file. */ if (prev_read == -1) { memset(&request->stream, 0, sizeof(request->stream)); - inflateInit(&request->stream); + git_inflate_init(&request->stream); git_SHA1_Init(&request->c); if (prev_posn>0) { prev_posn = 0; @@ -742,7 +742,7 @@ static void finish_request(struct transfer_request *request) if (request->http_code == 416) fprintf(stderr, "Warning: requested range invalid; we may already have all the data.\n"); - inflateEnd(&request->stream); + git_inflate_end(&request->stream); git_SHA1_Final(request->real_sha1, &request->c); if (request->zret != Z_STREAM_END) { unlink(request->tmpfile); |