Email List: Xaustin-group-lX
[All Lists]

Re: Stop signals and interruption of system calls on Linux

To: yyyyyyyyy@xxxxxxx (Michael T Kerrisk)
Subject: Re: Stop signals and interruption of system calls on Linux
From: "Wojtek Lerch" <yyyyyy@xxxxxxx>
Date: Fri, 13 Feb 2004 11:53:36 -0500 (EST)
Cc: yyyyyyyyyyyyyy@xxxxxxxxxxxxx
Michael T Kerrisk wrote:
> On Linux, the delivery of a stop signal (SIGTSTP, SIGSTOP, etc) 
> plus subsequent SIGCONT can cause a certain blocking system calls 
> (e.g., semop()) to return EINTR **even if the program is not 
> catching the stop signal**.  

POSIX allows functions to fail for reasons not mentioned in the
standard, and, unfortunately, does not forbid such failures to return
EINTR.  Error codes are much less meaningful than most of us assume in
everyday programming.


"Implementations may support additional errors not included in this
list, may generate errors included in this list under circumstances
      ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
other than those described here, or may contain extensions or
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
limitations that prevent some errors from occurring. The ERRORS section
on each reference page specifies whether an error shall be returned, or
whether it may be returned. Implementations shall not generate a
different error number from the ones described here for error conditions
described in this 1003.1-2001, but may generate additional errors
Stdvolume of IEEE unless explicitly disallowed for a particular
function."


<Prev in Thread] Current Thread [Next in Thread>