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

Re: [PATCH] Use macro HANDLER_WRAPPER in sigchain to wrap clean function of sigchain

From
徐迪 <xudifsd@gmail.com>
Date
Mar 15, 2012, 10:35 UTC
Message-ID
<CAMocUqRuKXoNAmqzcxvDmt4Oo=NqkM=5WyqgDqfDBMcTK0Cq7w@mail.gmail.com>
In-Reply-To
<7vlin4td4g.fsf@alter.siamese.dyndns.org>

Eh. I really don't see why it is difficult to read. Although it _is_ error-prone, and also difficult to do further functionality extension.

BTW, if we want to generalize the clean_xxx_on_signal, how should we deal with the exception I mentioned before(function named cleanup_children in run-command.c which require one argument)? By forcing all clean_xxx take one argument?

Also, many books mentioned that we should never use signal() in portable program, use sigaction() instead, but there are plenty of signal() in git. Why should we do so?

Previous: Junio C Hamano
Message 5 of 5 in “Use macro HANDLER_WRAPPER in sigchain to wrap clean function of sigchain”
  1. Use macro HANDLER_WRAPPER in sigchain to wrap clean function of sigchain徐迪, Mar 13, 2012
  2. Junio C HamanoMar 13, 2012
  3. Jeff KingMar 13, 2012
  4. Junio C HamanoMar 13, 2012
  5. 徐迪Mar 15, 2012

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.