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

Re: [Q] what to do when waitpid() returns ECHILD under signal(SIGCHLD, SIG_IGN)?

From
Linus Torvalds <torvalds@osdl.org>
Date
Jun 20, 2006, 00:44 UTC
Message-ID
<Pine.LNX.4.64.0606191742470.5498@g5.osdl.org>
In-Reply-To
<7vfyi07jf2.fsf@assigned-by-dhcp.cox.net>
On Mon, 19 Jun 2006, Junio C Hamano wrote:
Show 9 quoted lines
>
> Linus Torvalds <torvalds@osdl.org> writes:
> 
> > Whether we want to do that in the main() routine or when we actually do 
> > the fork() or whatever is a different issue.
> 
> I do not offhand think of a place where we do fork() but not
> waitpid(), and it is very tempting to cheat and do that in the
> main(), since I do not see a downside to it.

Yeah, it probably does make sense. That said, there are several "main()" functions, so you'd still end up having to verify that we catch all the paths.. Are all users of fork() built-in by now?

			Linus
Previous: Junio C HamanoNext: Junio C Hamano
Message 4 of 7 in “[Q] what to do when waitpid() returns ECHILD under signal(SIGCHLD, SIG_IGN)?”
  1. Junio C HamanoJun 19, 2006
  2. Linus TorvaldsJun 19, 2006
  3. Junio C HamanoJun 20, 2006
  4. Linus TorvaldsJun 20, 2006
  5. Restore SIGCHLD to SIG_DFL where we care about waitpid().Junio C Hamano, Jun 20, 2006
  6. Petr BaudisJun 20, 2006
  7. Edgar ToernigJun 20, 2006

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.