lkml.org 
[lkml]   [1998]   [Nov]   [24]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
From
SubjectRE: Possible bug in wait4(), 2.1.126-129 ?
On Tue, 24 Nov 1998, Guest section DW wrote:

> The following program

[...]

> demonstrates the behaviour of a reported ECHILD without
> the need for cron. Now it is immediately clear what the
> problem is.

Too bad it's not documented anywhere. All the (Linux) documentation I had
access to said that the above behavior cannot happen. I didn't help that
running the program under strace _did_ show a SIGCHLD being delivered...

And it's not like the behavior is very intuitive either. This being Un*x,
I would expect that SIG_IGN means just that the signal is ignored.
Instead, for this particular signal, the kernel does something behind my
back and silently reaps the children. Note, I'm not arguing that one
behavior is better that another, I realize that there are strong
compatibility reasons behind the current implementation.

> Note that POSIX explicitly disallows setting the action
> of SIGCHLD to SIG_IGN. It follows that crond and atd are
> not POSIX compliant.

Never mind POSIX though, as long as Linux allows it it ought to be
documented, even if it has a big warning before it. Solaris certainly does
-- I posted yesterday an excerpt from the Solaris signal(2) man page. Hint
for the Linux man pages maintainer? :-)

Thanks,
Ion

--
It is better to keep your mouth shut and be thought a fool,
than to open it and remove all doubt.


-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.rutgers.edu
Please read the FAQ at http://www.tux.org/lkml/

\
 
 \ /
  Last update: 2005-03-22 13:45    [W:2.291 / U:0.784 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site