git/mergetools
David Aguilar 571f4348dd mergetools/xxdiff: prevent segfaults from stopping difftool
Users often use "git difftool HEAD^" to review their work, and have
"mergetool.prompt" set to false so that difftool does not prompt them
before diffing each file.

This is very convenient because users can see all their diffs by
reviewing the xxdiff windows one at a time.

A problem occurs when xxdiff encounters some binary files.
It can segfault and return exit code 128, which is special-cased
by git-difftool-helper as being an extraordinary situation that
aborts the process.

Suppress the exit code from xxdiff in its diff_cmd() implementation
when we see exit code 128 so that the GIT_EXTERNAL_DIFF loop continues
on uninterrupted to the next file rather than aborting when it
encounters the first binary file.

Signed-off-by: David Aguilar <davvid@gmail.com>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
2021-10-13 11:04:04 -07:00
..
araxis mergetool: honor mergetool.$tool.trustExitCode for built-in tools 2016-11-29 10:54:03 -08:00
bc mergetools/bc: add bc4 to the alias list for Beyond Compare 2020-11-11 13:00:10 -08:00
codecompare mergetool: honor mergetool.$tool.trustExitCode for built-in tools 2016-11-29 10:54:03 -08:00
deltawalker mergetool: honor mergetool.$tool.trustExitCode for built-in tools 2016-11-29 10:54:03 -08:00
diffmerge mergetool: honor mergetool.$tool.trustExitCode for built-in tools 2016-11-29 10:54:03 -08:00
diffuse mergetool: honor mergetool.$tool.trustExitCode for built-in tools 2016-11-29 10:54:03 -08:00
ecmerge mergetool: honor mergetool.$tool.trustExitCode for built-in tools 2016-11-29 10:54:03 -08:00
emerge mergetool: honor mergetool.$tool.trustExitCode for built-in tools 2016-11-29 10:54:03 -08:00
examdiff mergetool: honor mergetool.$tool.trustExitCode for built-in tools 2016-11-29 10:54:03 -08:00
guiffy mergetools: add support for guiffy 2018-04-06 08:11:39 +09:00
gvimdiff mergetools: simplify how we handle "vim" and "defaults" 2013-01-28 19:00:38 -08:00
kdiff3 mergetools/kdiff3: make kdiff3 work on Windows too 2021-06-08 10:26:16 +09:00
kompare mergetool: honor mergetool.$tool.trustExitCode for built-in tools 2016-11-29 10:54:03 -08:00
meld mergetool: allow auto-merge for meld to follow the vim-diff behavior 2020-09-16 17:11:20 -07:00
nvimdiff mergetools: add support for nvimdiff (neovim) family 2020-07-29 14:44:49 -07:00
opendiff mergetool: honor mergetool.$tool.trustExitCode for built-in tools 2016-11-29 10:54:03 -08:00
p4merge mergetool: honor mergetool.$tool.trustExitCode for built-in tools 2016-11-29 10:54:03 -08:00
smerge mergetools: add support for smerge (Sublime Merge) 2019-04-04 18:21:25 +09:00
tkdiff mergetool: honor mergetool.$tool.trustExitCode for built-in tools 2016-11-29 10:54:03 -08:00
tortoisemerge mergetool: honor mergetool.$tool.trustExitCode for built-in tools 2016-11-29 10:54:03 -08:00
vimdiff mergetools/vimdiff: add vimdiff1 merge tool variant 2021-02-23 11:37:13 -08:00
winmerge mergetool: honor mergetool.$tool.trustExitCode for built-in tools 2016-11-29 10:54:03 -08:00
xxdiff mergetools/xxdiff: prevent segfaults from stopping difftool 2021-10-13 11:04:04 -07:00