git/list[1] front-page[2] threads[3] people[4] search[5] about
 

Re: [PATCH] ll-merge: killing the external merge driver aborts the merge

From
Junio C Hamano <gitster@pobox.com>
Date
Jun 27, 2023, 21:26 UTC
Message-ID
<xmqqilb8fvgu.fsf@gitster.g>
In-Reply-To
<cd5046d4-d66c-9dac-87e7-cdb638124170@cedaron.com>
Joshua Hudson <jhudson@cedaron.com> writes:
> Try changing kill -9 $$ to exit 137 # 128 + 9

Yeah, but then (1) we are not simulating a case where the external merge driver hits a segfault or receives a signal from outside and dies involuntarily, and (2) we are codifying that even on Windows, program that was killed by signal N must exit with 128 + N, and these are the reasons why I did not go that route.

Stepping back a bit, how does one typically diagnose programatically on Windows, after "spawning" a separate program, if the program died involuntarily and/or got killed? It does not have to be "exit with 128 + signal number"---as long as it can be done programatically and reliably, we would be happy. The code to diagnose how the spawned program exited in run_command(), which is in finish_command() and then in wait_or_whine(), may have to be updated with such a piece of Windows specific knowledge.

Previous: Joshua HudsonNext: Joshua Hudson
Message 14 of 15 in “Design issue in git merge driver interface”
  1. Joshua HudsonJun 22, 2023
  2. Junio C HamanoJun 22, 2023
  3. ll-merge: killing the external merge driver aborts the mergeJunio C Hamano, Jun 23, 2023
  4. Elijah NewrenJun 23, 2023
  5. Junio C HamanoJun 23, 2023
  6. Junio C HamanoJun 23, 2023
  7. Joshua HudsonJun 25, 2023
  8. Johannes SchindelinJun 27, 2023
  9. Joshua HudsonJun 27, 2023
  10. Junio C HamanoJun 27, 2023
  11. Joshua HudsonJun 27, 2023
  12. Junio C HamanoJun 27, 2023
  13. Joshua HudsonJun 27, 2023
  14. Junio C HamanoJun 27, 2023
  15. Joshua HudsonJun 27, 2023

Read the whole thread, see it on lore, or plain text.

$ cat FOOTERMessages come from the public archive at lore.kernel.org/git, fetched every hour. The front page is chosen and written each morning by an AI editor and can be wrong; the threads themselves are the record. About and API. For agents: an MCP server at https://gitlist.dev/mcp, and any thread, story or person page as Markdown by adding .md to its URL (or sending Accept: text/markdown). Details in /llms.txt.