X-Git-Url: https://git.tokkee.org/?a=blobdiff_plain;f=builtin-describe.c;h=3da99c1d06f1eeb85e760036dc881282558603d6;hb=4ec22a48c0575c8a303cd00b5ef4b3d703fbf8b3;hp=df554b30af3ddcb4d0141838c06f82d433cbf3a4;hpb=6abf189506712a0e3c5ea796d136177b8f24ca22;p=git.git diff --git a/builtin-describe.c b/builtin-describe.c index df554b30a..3da99c1d0 100644 --- a/builtin-describe.c +++ b/builtin-describe.c @@ -80,12 +80,13 @@ static int get_name(const char *path, const unsigned char *sha1, int flag, void * Otherwise only annotated tags are used. */ if (might_be_tag) { - if (is_tag) { + if (is_tag) prio = 2; - if (pattern && fnmatch(pattern, path + 10, 0)) - prio = 0; - } else + else prio = 1; + + if (pattern && fnmatch(pattern, path + 10, 0)) + prio = 0; } else prio = 0;