mirror of
https://github.com/git/git
synced 2024-08-24 18:26:02 +00:00
show_head_ref(): do not shadow name of argument
Signed-off-by: Michael Haggerty <mhagger@alum.mit.edu> Signed-off-by: Junio C Hamano <gitster@pobox.com>
This commit is contained in:
parent
f83918edcb
commit
1d811dbd04
|
@ -416,8 +416,8 @@ static int show_head_ref(const char *name, const unsigned char *sha1,
|
|||
struct strbuf *buf = cb_data;
|
||||
|
||||
if (flag & REF_ISSYMREF) {
|
||||
unsigned char sha1[20];
|
||||
const char *target = resolve_ref_unsafe(name, sha1, 1, NULL);
|
||||
unsigned char unused[20];
|
||||
const char *target = resolve_ref_unsafe(name, unused, 1, NULL);
|
||||
const char *target_nons = strip_namespace(target);
|
||||
|
||||
strbuf_addf(buf, "ref: %s\n", target_nons);
|
||||
|
|
Loading…
Reference in a new issue