summary | shortlog | log | commit | commitdiff | tree
raw | patch | inline | side by side (parent: 870cf7d)
raw | patch | inline | side by side (parent: 870cf7d)
author | Junio C Hamano <gitster@pobox.com> | |
Mon, 3 Mar 2008 23:54:23 +0000 (15:54 -0800) | ||
committer | Junio C Hamano <gitster@pobox.com> | |
Mon, 3 Mar 2008 23:54:23 +0000 (15:54 -0800) |
It is implausible for lookup_tag() to return NULL in this particular
codepath but we should protect ourselves against a broken repository
better.
Signed-off-by: Junio C Hamano <gitster@pobox.com>
codepath but we should protect ourselves against a broken repository
better.
Signed-off-by: Junio C Hamano <gitster@pobox.com>
builtin-describe.c | patch | blob | history |
diff --git a/builtin-describe.c b/builtin-describe.c
index 43be671827ee1ec1b9bebb61f803059e674ad5a2..7a5ab012b1fabe3f67cd2d9bc776794e34431d80 100644 (file)
--- a/builtin-describe.c
+++ b/builtin-describe.c
{
if (n->prio == 2 && !n->tag) {
n->tag = lookup_tag(n->sha1);
- if (parse_tag(n->tag) || !n->tag || !n->tag->tag)
+ if (!n->tag || parse_tag(n->tag) || !n->tag->tag)
die("annotated tag %s not available", n->path);
if (strcmp(n->tag->tag, n->path))
warning("tag '%s' is really '%s' here", n->tag->tag, n->path);