sigprocmask(2) DG/UX 4.30 sigprocmask(2)
NAME
sigprocmask - Examine and change blocked signals.
SYNOPSIS
#include <signal.h>
int sigprocmask (how, set, oset)
int how;
sigset_t *set, *oset;
DESCRIPTION
The sigprocmask function is used to examine or change (or
both) the calling process's signal mask. If the value of
the argument set is not NULL, it points to a set of signals
to be used to change the currently blocked set.
The value of the argument how indicates the manner in which
the set is changed, and shall consist of one of the
following values, as defined in the header <signal.h>.
Name Description
SIG_BLOCK The resulting set shall be the
union of the current set and the
signal set pointed to by the
argument set.
SIG_UNBLOCK The resulting set shall be the
intersection of the current set and
the complement of the signal set
pointed to by the argument set.
SIG_SETMASK The resulting set shall be the
signal set pointed to by the
argument set.
If the argument oset is not NULL, the previous mask is
stored in the space pointed to by oset. If the value of the
argument set is NULL, the value of the argument how is not
significant and the process's signal mask is unchanged by
this function call; thus, the call can be used to enquire
about currently blocked signals.
If there are any pending unblocked signals after the call to
the sigprocmask function, at least one of those signals
shall be delivered before the sigprocmask function returns.
It is not possible to block the SIGKILL and SIGSTOP signals;
this shall be enforced by the system without causing an
error to be indicated.
If any of the SIGFPE, SIGILL, or SIGSEGV signals are
Licensed material--property of copyright holder(s) Page 1
sigprocmask(2) DG/UX 4.30 sigprocmask(2)
generated while they are blocked, the result is undefined,
unless the signal was generated by a call to the kill
function or the raise function defined by the C Standard.
If the sigprocmask function fails, the process's signal mask
is not changed by this function call.
RETURNS
Upon successful completion a value of zero is returned.
Otherwise, a value of -1 is returned and errno is set to
indicate the error.
ERRORS
If any of the following conditions occur, the sigprocmask
function shall return -1 and set errno to the corresponding
value:
[EINVAL]
The value of the how argument is not equal to one of
the defined values.
SEE ALSO
sigaction(2), <signal.h>, sigpending(2), sigsetops(3),
sigsuspend(2)
COPYRIGHTS
Portions of this text are reprinted from IEEE Std 1003.1-
1988, Portable Operating System Interface for Computer
Environment, copyright © 1988 by the Institute of Electrical
and Electronics Engineers, Inc., with the permission of the
IEEE Standards Department. To purchase IEEE Standards, call
800/678-IEEE.
In the event of a discrepancy between the electronic and the
original printed version, the original version takes
precedence.
Licensed material--property of copyright holder(s) Page 2