summaryrefslogtreecommitdiff
path: root/builtin/update-ref.c
diff options
context:
space:
mode:
authorLibravatar brian m. carlson <sandals@crustytoothpaste.net>2017-10-15 22:06:51 +0000
committerLibravatar Junio C Hamano <gitster@pobox.com>2017-10-16 11:05:50 +0900
commitae077771b09fac4d663e3f8c039318a97eb3a15b (patch)
tree53b4ed92e41aad737b49a44fc60871f7df1445dc /builtin/update-ref.c
parentrefs: convert delete_ref and refs_delete_ref to struct object_id (diff)
downloadtgif-ae077771b09fac4d663e3f8c039318a97eb3a15b.tar.xz
refs: convert update_ref and refs_update_ref to use struct object_id
Convert update_ref, refs_update_ref, and write_pseudoref to use struct object_id. Update the existing callers as well. Remove update_ref_oid, as it is no longer needed. Signed-off-by: brian m. carlson <sandals@crustytoothpaste.net> Signed-off-by: Junio C Hamano <gitster@pobox.com>
Diffstat (limited to 'builtin/update-ref.c')
-rw-r--r--builtin/update-ref.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/builtin/update-ref.c b/builtin/update-ref.c
index bf0f80ebae..f491cf1a92 100644
--- a/builtin/update-ref.c
+++ b/builtin/update-ref.c
@@ -437,7 +437,7 @@ int cmd_update_ref(int argc, const char **argv, const char *prefix)
(oldval && !is_null_oid(&oldoid)) ? &oldoid : NULL,
flags);
else
- return update_ref(msg, refname, oid.hash, oldval ? oldoid.hash : NULL,
+ return update_ref(msg, refname, &oid, oldval ? &oldoid : NULL,
flags | create_reflog_flag,
UPDATE_REFS_DIE_ON_ERR);
}