diff options
| author | Elijah Newren <newren@gmail.com> | 2026-08-29 07:00:28 +0000 |
|---|---|---|
| committer | Junio C Hamano <gitster@pobox.com> | 2026-08-30 13:37:42 -0700 |
| commit | b6f5e80fdf32c270ff812c1743e720dedca7d5e2 (patch) | |
| tree | e8cc71109ecad96f05f94cc6fd77d004d4657943 /gitweb | |
| parent | 48fc56621cbea18dd0f23a87af90b7a930d1e1d2 (diff) | |
replay: fail gracefully when a merge input is unreadable
When objects involved in the merge cannot be read, the merge machinery
will return early with result.clean = -1, and result.tree left as NULL.
pick_regular_commit() tested only "if (!result->clean)", ignoring the
case where "clean < 0". That causes the code to try to use
result->tree, resulting in a SIGSEGV.
Handle clean < 0 explicitly; the merge machinery will already have printed
messages such as "Could not read <object>" and "collecting merge info
failed for trees...", so we don't need to add much detail beyond the
fact that the merge failed.
Signed-off-by: Elijah Newren <newren@gmail.com>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
Diffstat (limited to 'gitweb')
0 files changed, 0 insertions, 0 deletions
