From 744c040b19412fa5075810eb1aced105fad96726 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Ren=C3=A9=20Scharfe?= Date: Sat, 23 Sep 2017 11:45:04 +0200 Subject: refs: pass NULL to resolve_ref_unsafe() if hash is not needed This allows us to get rid of some write-only variables, among them seven SHA1 buffers. Signed-off-by: Rene Scharfe Signed-off-by: Junio C Hamano --- http-backend.c | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) (limited to 'http-backend.c') diff --git a/http-backend.c b/http-backend.c index 8076b1d5e5..b8ce960a35 100644 --- a/http-backend.c +++ b/http-backend.c @@ -486,10 +486,9 @@ static int show_head_ref(const char *refname, const struct object_id *oid, struct strbuf *buf = cb_data; if (flag & REF_ISSYMREF) { - struct object_id unused; const char *target = resolve_ref_unsafe(refname, RESOLVE_REF_READING, - unused.hash, NULL); + NULL, NULL); if (target) strbuf_addf(buf, "ref: %s\n", strip_namespace(target)); -- cgit v1.2.3