Commit 422b2063 authored by Lea Wiemann's avatar Lea Wiemann Committed by Junio C Hamano

cat-file --batch: flush stdout also when objects are missing

cat-file --batch/--batch-check only flushes stdout when the object
exists, but not when it doesn't ("<object> missing").  This makes
bidirectional pipes hang.
Signed-off-by: default avatarLea Wiemann <[email protected]>
Signed-off-by: default avatarJunio C Hamano <[email protected]>
parent 02c17196
......@@ -159,6 +159,7 @@ static int batch_one_object(const char *obj_name, int print_contents)
if (get_sha1(obj_name, sha1)) {
printf("%s missing\n", obj_name);
fflush(stdout);
return 0;
}
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment