summaryrefslogtreecommitdiff
path: root/compat/mingw.c
diff options
context:
space:
mode:
authorLibravatar Johannes Schindelin <johannes.schindelin@gmx.de>2018-11-29 05:01:54 -0800
committerLibravatar Junio C Hamano <gitster@pobox.com>2018-11-30 14:43:00 +0900
commit8797f0f008722537f56ed0bf16ebec45682b7497 (patch)
treedd777f011f7058ac6521de61642f2d942867bac9 /compat/mingw.c
parentMerge branch 'ja/i18n-fix' (diff)
downloadtgif-8797f0f008722537f56ed0bf16ebec45682b7497.tar.xz
rebase --stat: fix when rebasing to an unrelated history
When rebasing to a commit history that has no common commits with the current branch, there is no merge base. In diffstat mode, this means that we cannot compare to the merge base, but we have to compare to the empty tree instead. Also, if running in verbose diffstat mode, we should not output Changes from <merge-base> to <onto> as that does not make sense without any merge base. Note: neither scripted nor built-in versoin of `git rebase` were prepared for this situation well. We use this opportunity not only to fix the bug(s), but also to make both versions' output consistent in this instance. And add a regression test to keep this working in all eternity. Reported-by: Ævar Arnfjörð Bjarmason <avarab@gmail.com> Signed-off-by: Johannes Schindelin <johannes.schindelin@gmx.de> Signed-off-by: Junio C Hamano <gitster@pobox.com>
Diffstat (limited to 'compat/mingw.c')
0 files changed, 0 insertions, 0 deletions