diff options
author | Junio C Hamano <gitster@pobox.com> | 2017-09-28 14:47:56 +0900 |
---|---|---|
committer | Junio C Hamano <gitster@pobox.com> | 2017-09-28 14:47:56 +0900 |
commit | 73ecdc606eedbfd98ec66d50d44b3374425fd13b (patch) | |
tree | 6a2aeb6eb0b30e1645c8af06b10c9f4ec2815dd8 /upload-pack.c | |
parent | Merge branch 'rs/mailinfo-qp-decode-fix' (diff) | |
parent | refs: pass NULL to resolve_ref_unsafe() if hash is not needed (diff) | |
download | tgif-73ecdc606eedbfd98ec66d50d44b3374425fd13b.tar.xz |
Merge branch 'rs/resolve-ref-optional-result'
Code clean-up.
* rs/resolve-ref-optional-result:
refs: pass NULL to resolve_ref_unsafe() if hash is not needed
refs: pass NULL to refs_resolve_ref_unsafe() if hash is not needed
refs: make sha1 output parameter of refs_resolve_ref_unsafe() optional
Diffstat (limited to 'upload-pack.c')
-rw-r--r-- | upload-pack.c | 3 |
1 files changed, 1 insertions, 2 deletions
diff --git a/upload-pack.c b/upload-pack.c index 7efff2fbfd..06d822aad2 100644 --- a/upload-pack.c +++ b/upload-pack.c @@ -965,11 +965,10 @@ static int find_symref(const char *refname, const struct object_id *oid, { const char *symref_target; struct string_list_item *item; - struct object_id unused; if ((flag & REF_ISSYMREF) == 0) return 0; - symref_target = resolve_ref_unsafe(refname, 0, unused.hash, &flag); + symref_target = resolve_ref_unsafe(refname, 0, NULL, &flag); if (!symref_target || (flag & REF_ISSYMREF) == 0) die("'%s' is a symref but it is not?", refname); item = string_list_append(cb_data, refname); |