]> git.ipfire.org Git - thirdparty/git.git/commit - refs.h
refs: add an update_ref_oid function.
authorbrian m. carlson <sandals@crustytoothpaste.net>
Mon, 5 Sep 2016 20:08:08 +0000 (20:08 +0000)
committerJunio C Hamano <gitster@pobox.com>
Wed, 7 Sep 2016 19:59:43 +0000 (12:59 -0700)
commit8f6dc7e32eee2944d1490ff9bf12ec329f3b33c2
tree6d04aad2e1144fdd97b1c394b88e2bfcd5158e45
parent151b2911c1279f3ea4b5bcc069a04348aeb9d811
refs: add an update_ref_oid function.

Several places around the codebase want to pass update_ref data from
struct object_id, but update_ref may also be passed NULL pointers.
Instead of checking and dereferencing in every caller, create an
update_ref_oid which wraps update_ref and provides this functionality.

Signed-off-by: brian m. carlson <sandals@crustytoothpaste.net>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
refs.c
refs.h