1
0
Fork 0
mirror of https://github.com/git/git.git synced 2024-05-23 05:36:09 +02:00

Merge branch 'rs/describe-unique-abbrev'

Code clean-up.

* rs/describe-unique-abbrev:
  describe: use strbuf_add_unique_abbrev() for adding short hashes
This commit is contained in:
Junio C Hamano 2018-02-13 13:39:07 -08:00
commit 8fe806bcd5

View File

@ -383,7 +383,7 @@ static void describe_commit(struct object_id *oid, struct strbuf *dst)
if (!match_cnt) {
struct object_id *cmit_oid = &cmit->object.oid;
if (always) {
strbuf_addstr(dst, find_unique_abbrev(cmit_oid->hash, abbrev));
strbuf_add_unique_abbrev(dst, cmit_oid->hash, abbrev);
if (suffix)
strbuf_addstr(dst, suffix);
return;