summaryrefslogtreecommitdiff
path: root/check_bindir
diff options
context:
space:
mode:
authorLibravatar Johannes Schindelin <johannes.schindelin@gmx.de>2020-12-19 14:55:59 +0000
committerLibravatar Junio C Hamano <gitster@pobox.com>2020-12-21 14:06:09 -0800
commit5c29f19cdada762e75939a946df21b44d48d6fff (patch)
treebdc9d8ad8daf17aee9dff42c439c46b74968a342 /check_bindir
parentt2016: add a NEEDSWORK about the PERL prerequisite (diff)
downloadtgif-5c29f19cdada762e75939a946df21b44d48d6fff.tar.xz
checkout -p: handle tree arguments correctly again
This fixes a segmentation fault. The bug is caused by dereferencing `new_branch_info->commit` when it is `NULL`, which is the case when the tree-ish argument is actually a tree, not a commit-ish. This was introduced in 5602b500c3c (builtin/checkout: fix `git checkout -p HEAD...` bug, 2020-10-07), where we tried to ensure that the special tree-ish `HEAD...` is handled correctly. Signed-off-by: Johannes Schindelin <johannes.schindelin@gmx.de> Signed-off-by: Junio C Hamano <gitster@pobox.com>
Diffstat (limited to 'check_bindir')
0 files changed, 0 insertions, 0 deletions