summary | shortlog | log | commit | commitdiff | tree
raw | patch | inline | side by side (parent: 0058a33)
raw | patch | inline | side by side (parent: 0058a33)
author | Junio C Hamano <gitster@pobox.com> | |
Sat, 25 Aug 2007 08:26:20 +0000 (01:26 -0700) | ||
committer | Junio C Hamano <gitster@pobox.com> | |
Sat, 25 Aug 2007 15:33:47 +0000 (08:33 -0700) |
Signed-off-by: Junio C Hamano <gitster@pobox.com>
builtin-blame.c | patch | blob | history |
diff --git a/builtin-blame.c b/builtin-blame.c
index 0519339098f3258ae6cc2b50d30679a8cfc7f2c7..dc88a953a519e975f426f6158b73542a2ea120dd 100644 (file)
--- a/builtin-blame.c
+++ b/builtin-blame.c
num_read_blob++;
file->ptr = read_sha1_file(o->blob_sha1, &type,
(unsigned long *)(&(file->size)));
+ if (!file->ptr)
+ die("Cannot read blob %s for path %s",
+ sha1_to_hex(o->blob_sha1),
+ o->path);
o->file = *file;
}
else
unsigned long size;
commit->buffer =
read_sha1_file(commit->object.sha1, &type, &size);
+ if (!commit->buffer)
+ die("Cannot read commit %s",
+ sha1_to_hex(commit->object.sha1));
}
ret->author = author_buf;
get_ac_line(commit->buffer, "\nauthor ",
sb.final_buf = read_sha1_file(o->blob_sha1, &type,
&sb.final_buf_size);
+ if (!sb.final_buf)
+ die("Cannot read blob %s for path %s",
+ sha1_to_hex(o->blob_sha1),
+ path);
}
num_read_blob++;
lno = prepare_lines(&sb);