summaryrefslogtreecommitdiff
path: root/transport.c
diff options
context:
space:
mode:
authorRené Scharfe <l.s.r@web.de>2017-10-01 09:29:03 +0200
committerJunio C Hamano <gitster@pobox.com>2017-10-01 17:27:14 +0900
commitefbd4fdfc9978bf3872ca8cf390da4ffa3480188 (patch)
treeb3e8b62af87e612724c2b4a95dc2cbf1c94f6e90 /transport.c
parent872ccb2c69ce44abb198efa1013dd4e0887a7495 (diff)
downloadgit-efbd4fdfc9978bf3872ca8cf390da4ffa3480188.tar.gz
refs: pass NULL to resolve_refdup() if hash is not neededrs/resolve-ref-optional-result
This allows us to get rid of several write-only variables. Signed-off-by: Rene Scharfe <l.s.r@web.de> Signed-off-by: Junio C Hamano <gitster@pobox.com>
Diffstat (limited to 'transport.c')
-rw-r--r--transport.c3
1 files changed, 1 insertions, 2 deletions
diff --git a/transport.c b/transport.c
index fb8c01e57a..f1e2f61991 100644
--- a/transport.c
+++ b/transport.c
@@ -471,11 +471,10 @@ void transport_print_push_status(const char *dest, struct ref *refs,
{
struct ref *ref;
int n = 0;
- struct object_id head_oid;
char *head;
int summary_width = transport_summary_width(refs);
- head = resolve_refdup("HEAD", RESOLVE_REF_READING, head_oid.hash, NULL);
+ head = resolve_refdup("HEAD", RESOLVE_REF_READING, NULL, NULL);
if (verbose) {
for (ref = refs; ref; ref = ref->next)