int sigblock(int mask);
int siggetmask(void);
int sigsetmask(int mask);
int sigmask(signum);
Sigblock() adds the signals specified in mask to the set of signals currently being blocked from delivery.
sigsetmask() replaces the set of blocked signals totally with a new set specified in mask.
Signals are blocked if the corresponding bit in mask is a 1; the macro sigmask is provided to construct the mask for a given signum.
It is not possible to block SIGKILL or SIGSTOP; this restriction is silently imposed by the system.
The current set of blocked signals can be obtained using siggetmask().
Sigsetmask() and sigblock() return the previous set of masked signals.