summaryrefslogtreecommitdiff
path: root/sha1_file.c
diff options
context:
space:
mode:
authorNicolas Pitre <nico@cam.org>2006-12-20 18:34:05 (GMT)
committerJunio C Hamano <junkio@cox.net>2006-12-20 18:46:34 (GMT)
commit08a19d873c16aa6127bf4c40cf99a9dd19558a0c (patch)
tree8f2e561d52364489ce05b513b754a9abb8abce46 /sha1_file.c
parent85023577a8f4b540aa64aa37f6f44578c0c305a3 (diff)
downloadgit-08a19d873c16aa6127bf4c40cf99a9dd19558a0c.zip
git-08a19d873c16aa6127bf4c40cf99a9dd19558a0c.tar.gz
git-08a19d873c16aa6127bf4c40cf99a9dd19558a0c.tar.bz2
clarify some error messages wrt unknown object types
If ever new object types are added for future extensions then better have current git version report them as "unknown" instead of "corrupted". Signed-off-by: Nicolas Pitre <nico@cam.org> Signed-off-by: Junio C Hamano <junkio@cox.net>
Diffstat (limited to 'sha1_file.c')
-rw-r--r--sha1_file.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/sha1_file.c b/sha1_file.c
index 63f416b..1c4df5b 100644
--- a/sha1_file.c
+++ b/sha1_file.c
@@ -1013,7 +1013,7 @@ void packed_object_info_detail(struct packed_git *p,
for (;;) {
switch (kind) {
default:
- die("corrupted pack file %s containing object of kind %d",
+ die("pack %s contains unknown object type %d",
p->pack_name, kind);
case OBJ_COMMIT:
case OBJ_TREE:
@@ -1063,7 +1063,7 @@ static int packed_object_info(struct packed_git *p, unsigned long offset,
strcpy(type, type_names[kind]);
break;
default:
- die("corrupted pack file %s containing object of kind %d",
+ die("pack %s contains unknown object type %d",
p->pack_name, kind);
}
if (sizep)