summaryrefslogtreecommitdiff
path: root/sha1_name.c
diff options
context:
space:
mode:
Diffstat (limited to 'sha1_name.c')
-rw-r--r--sha1_name.c4
1 files changed, 4 insertions, 0 deletions
diff --git a/sha1_name.c b/sha1_name.c
index faf873cf7f..0ff83a9985 100644
--- a/sha1_name.c
+++ b/sha1_name.c
@@ -327,6 +327,10 @@ static int get_short_sha1(const char *name, int len, unsigned char *sha1,
prepare_alt_odb();
memset(&ds, 0, sizeof(ds));
+
+ if (HAS_MULTI_BITS(flags & GET_SHA1_DISAMBIGUATORS))
+ die("BUG: multiple get_short_sha1 disambiguator flags");
+
if (flags & GET_SHA1_COMMIT)
ds.fn = disambiguate_commit_only;
else if (flags & GET_SHA1_COMMITTISH)