]> git.ipfire.org Git - thirdparty/git.git/commit - builtin/cat-file.c
cat-file: stop returning value from batch_one_object
authorJeff King <peff@peff.net>
Mon, 22 Jun 2015 10:45:33 +0000 (06:45 -0400)
committerJunio C Hamano <gitster@pobox.com>
Mon, 22 Jun 2015 21:55:52 +0000 (14:55 -0700)
commit82330950d96a2c2b971ec5b29f59625bcfb62d47
treea2a7dc139246554d923584aecb42ee616f34b9ea
parentfc4937c37219347f4e2c25a271577b333942453f
cat-file: stop returning value from batch_one_object

If batch_one_object returns an error code, we stop reading
input.  However, it will only do so if we feed it NULL,
which cannot happen; we give it the "buf" member of a
strbuf, which is always non-NULL.

We did originally stop on other errors (like a missing
object), but this was changed in 3c076db (cat-file --batch /
--batch-check: do not exit if hashes are missing,
2008-06-09). These days we keep going for any per-object
error (and print "missing" when necessary).

Signed-off-by: Jeff King <peff@peff.net>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
builtin/cat-file.c