diff options
author | Junio C Hamano <gitster@pobox.com> | 2011-10-28 23:48:40 +0200 |
---|---|---|
committer | Junio C Hamano <gitster@pobox.com> | 2011-12-01 20:46:09 +0100 |
commit | 568508e76570e9ea36aad6446959424cebcf0535 (patch) | |
tree | 9b71da7197e9a084c3406d6020672dd11ac26b24 /zlib.c | |
parent | csum-file: introduce sha1file_checkpoint (diff) | |
download | git-568508e76570e9ea36aad6446959424cebcf0535.tar.xz git-568508e76570e9ea36aad6446959424cebcf0535.zip |
bulk-checkin: replace fast-import based implementation
This extends the earlier approach to stream a large file directly from the
filesystem to its own packfile, and allows "git add" to send large files
directly into a single pack. Older code used to spawn fast-import, but the
new bulk-checkin API replaces it.
Signed-off-by: Junio C Hamano <gitster@pobox.com>
Diffstat (limited to 'zlib.c')
-rw-r--r-- | zlib.c | 9 |
1 files changed, 8 insertions, 1 deletions
@@ -188,13 +188,20 @@ void git_deflate_init_gzip(git_zstream *strm, int level) strm->z.msg ? strm->z.msg : "no message"); } -void git_deflate_end(git_zstream *strm) +int git_deflate_abort(git_zstream *strm) { int status; zlib_pre_call(strm); status = deflateEnd(&strm->z); zlib_post_call(strm); + return status; +} + +void git_deflate_end(git_zstream *strm) +{ + int status = git_deflate_abort(strm); + if (status == Z_OK) return; error("deflateEnd: %s (%s)", zerr_to_string(status), |