lkml.org 
[lkml]   [2000]   [Nov]   [3]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
From
SubjectRe: Can EINTR be handled the way BSD handles it? -- a plea from a user-land programmer...
On Fri, 3 Nov 2000 george@moberg.com wrote:

> I don't mean this to sound like a rant. It's just that I can't possibly
> ascertain why someone in their right mind would want any behaviour
> different than SA_RESTART.

study apache 1.3's child_main code, you'll see an example of EINTR in use.
it's used to get out of accept() -- most specifically when the child needs
to die off (because the parent has determined that there's either too many
children, or because a shutdown/restart is occuring).

apache 1.3's BUFF code also uses EINTR for timeouts.

i eliminated signals in the 2.0 design... so it doesn't use EINTR any
more, but it restarts in userland because that's the most portable thing
to do.



On Fri, 3 Nov 2000 george@moberg.com wrote:

> After reading about SA_RESTART, ok. However, couldn't those
> applications that require it enable this behaviour explicitly?

anyone sane writing modern applications will use sigaction(). signal() is
legacy.

-dean

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

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