Merge branch 'rs/cocci'
Code clean-up with help from coccinelle tool continues. * rs/cocci: coccicheck: make transformation for strbuf_addf(sb, "...") more precise use strbuf_add_unique_abbrev() for adding short hashes, part 2 use strbuf_addstr() instead of strbuf_addf() with "%s", part 2 gitignore: ignore output files of coccicheck make target
This commit is contained in:
@ -1383,8 +1383,7 @@ static int grab_1st_switch(unsigned char *osha1, unsigned char *nsha1,
|
||||
if (!strcmp(cb->buf.buf, "HEAD")) {
|
||||
/* HEAD is relative. Resolve it to the right reflog entry. */
|
||||
strbuf_reset(&cb->buf);
|
||||
strbuf_addstr(&cb->buf,
|
||||
find_unique_abbrev(nsha1, DEFAULT_ABBREV));
|
||||
strbuf_add_unique_abbrev(&cb->buf, nsha1, DEFAULT_ABBREV);
|
||||
}
|
||||
return 1;
|
||||
}
|
||||
|
Reference in New Issue
Block a user