]> git.ipfire.org Git - thirdparty/git.git/commit
unpack-trees: keep gently check inside add_rejected_path
authorNguyễn Thái Ngọc Duy <pclouds@gmail.com>
Fri, 22 Mar 2019 09:31:35 +0000 (16:31 +0700)
committerJunio C Hamano <gitster@pobox.com>
Sun, 24 Mar 2019 12:35:34 +0000 (21:35 +0900)
commit191e9d2c2dac2aaf8cb7db854cec48028addfece
treee4f5d3c30a8cbfe4feefa571f386787d666fd1e9
parent041f5ea1cf987a4068ef5f39ba0a09be85952064
unpack-trees: keep gently check inside add_rejected_path

This basically follows the footsteps of 6a143aa2b2 (checkout -m:
attempt merge when deletion of path was staged - 2014-08-12) where
there gently check is moved inside reject_merge() so that callers do
not accidentally forget it.

add_rejected_path() has the same usage pattern. All call sites check
gently first, then decide to call add_rejected_path() if needed. Move
the check inside.

Signed-off-by: Nguyễn Thái Ngọc Duy <pclouds@gmail.com>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
unpack-trees.c