Andrew's git
/
gitweb.git
/ blobdiff
summary
|
log
|
commit
|
diff
|
tree
commit
grep
author
committer
pickaxe
?
re
Abstract out the "name <email> date" handling of commit-tree.c
[gitweb.git]
/
commit.c
diff --git
a/commit.c
b/commit.c
index 0bbfa2ab31917e2a7584b0267c04f3324fad28d9..caee5bc218f6db03ec4c8f16f39b892ebb7c762c 100644
(file)
--- a/
commit.c
+++ b/
commit.c
@@
-52,8
+52,9
@@
struct commit *lookup_commit_reference(const unsigned char *sha1)
if (!obj)
return NULL;
- if (obj->type == tag_type)
- obj = ((struct tag *)obj)->tagged;
+ while (obj->type == tag_type)
+ obj = parse_object(((struct tag *)obj)->tagged->sha1);
+
return check_commit(obj, sha1);
}