cat-file: refactor error handling of batch_objects
commit07e23839459465c1319c7ce91afaf01d3e31a97e
authorJeff King <peff@peff.net>
Tue, 7 Jan 2014 22:10:15 +0000 (7 17:10 -0500)
committerJunio C Hamano <gitster@pobox.com>
Tue, 7 Jan 2014 22:31:10 +0000 (7 14:31 -0800)
treec9eaebc26b18e260241a476fff6207316239737c
parent832cf74c0792a58c9c28e32a8fe5dbb694f0cce6
cat-file: refactor error handling of batch_objects

This just pulls the return value for the function out of the
inner loop, so we can break out of the loop rather than do
an early return. This will make it easier to put any cleanup
for the function in one place.

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