summaryrefslogtreecommitdiff
path: root/gettext.c
diff options
context:
space:
mode:
authorLibravatar Phillip Wood <phillip.wood@dunelm.org.uk>2022-01-26 13:05:43 +0000
committerLibravatar Junio C Hamano <gitster@pobox.com>2022-01-26 12:08:53 -0800
commit1526d0fcfd20efca24bc96a4bc14c8d5459ec470 (patch)
tree2dcea6100e2a8bb0446cd4ee97005ab8452d22d8 /gettext.c
parentreset_head(): factor out ref updates (diff)
downloadtgif-1526d0fcfd20efca24bc96a4bc14c8d5459ec470.tar.xz
reset_head(): make default_reflog_action optional
This parameter is only needed when a ref is going to be updated and the caller does not pass an explicit reflog message. Callers that are only discarding uncommitted changes in the working tree such as such as "rebase --skip" or create_autostash() do not update any refs so should not have to worry about passing this parameter. This change is not intended to have any user visible changes. The pointer comparison between `oid` and `&head_oid` checks that the caller did not pass an oid to be checked out. As no callers pass RESET_HEAD_RUN_POST_CHECKOUT_HOOK without passing an oid there are no changes to when the post-checkout hook is run. As update_ref() only updates the ref if the oid passed to it differs from the current ref there are no changes to when HEAD is updated. Signed-off-by: Phillip Wood <phillip.wood@dunelm.org.uk> Signed-off-by: Junio C Hamano <gitster@pobox.com>
Diffstat (limited to 'gettext.c')
0 files changed, 0 insertions, 0 deletions