*nix Documentation Project
·  Home
 +   man pages
·  Linux HOWTOs
·  FreeBSD Tips
·  *niX Forums

  man pages->IRIX man pages -> standard/sigprocmask (2)              
Title
Content
Arch
Section
 

Contents


SIGPROCMASK(2)							SIGPROCMASK(2)


NAME    [Toc]    [Back]

     sigprocmask - alter and return previous state of the set of blocked
     signals (POSIX)

SYNOPSIS    [Toc]    [Back]

     #include <signal.h>

     int sigprocmask(int operation, sigset_t *set, sigset_t *oset);

DESCRIPTION    [Toc]    [Back]

     sigprocmask manipulates the set of	signals	which are blocked from
     delivery to the thread.

     A non-NULL	set specifies the set of signals to use	in modifying the
     currently-active set, and the incoming signals may	be added to, deleted
     from, or completely replace the active set, as specified by the operation
     parameter,	which may have the following values (as	defined	in
     <signal.h>):

     SIG_NOP	    Do not alter current signal	mask
     SIG_BLOCK	    Add	specified signals to those in current mask
     SIG_UNBLOCK    Remove the specified signals from current mask
     SIG_SETMASK    Replace current mask with incoming one

     If	oset is	not NULL, the current set of blocked signals (before
     modification) is returned in the space to which it	points.	 In this way,
     with a NULL set and SIG_NOP operation the user can	determine the current
     signal mask.

     Routines described	in sigsetops(3)	are used to create and examine the set
     and oset signal masks.

     It	is not possible	to block SIGKILL or SIGSTOP; this restriction is
     silently imposed by the system.

     POSIX specifies (contrary to BSD and System V) that a thread may block
     SIGCONT.  However,	a) SIGCONT always restarts the receiving thread
     (unless it	is waiting for an event	such as	I/O), and b) if	the receiving
     process has installed a handler for SIGCONT and blocked the signal, the
     thread will NOT enter its handler until it	unblocks SIGCONT.  (The	signal
     will remain pending.)

     sigprocmask will fail if:

     [EFAULT]	    set	or oset	point to memory	that is	not a part of the
		    process's valid address space.

     [EINVAL]	    Operation is not a valid set-operation (as described
		    above: SIG_NOP, SIG_BLOCK, SIG_UNBLOCK, or SIG_SETMASK).






									Page 1






SIGPROCMASK(2)							SIGPROCMASK(2)


SEE ALSO    [Toc]    [Back]

      
      
     kill(2), sigaction(2), sigpending(2), sigsuspend(2), sigsetops(3).

DIAGNOSTICS    [Toc]    [Back]

     A 0 value indicates that the call succeeded.  A -1	return value indicates
     that an error occurred and	errno is set to	indicate the reason.

WARNING    [Toc]    [Back]

     The POSIX and System V signal facilities have different semantics.	 Using
     both facilities in	the same program is strongly discouraged and will
     result in unpredictable behavior.


									PPPPaaaaggggeeee 2222
[ Back ]
 Similar pages
Name OS Title
sigsuspend IRIX atomically release blocked signals and wait for interrupt (POSIX)
sigpending IRIX return set of signals pending for thread (POSIX)
pxfsigprocmask IRIX Examines and changes blocked signals
pthread_sigmask IRIX examine and change blocked signals
sigprocmask HP-UX examine and change blocked signals
sigpause OpenBSD atomically release blocked signals and wait for interrupt
sigsuspend NetBSD atomically release blocked signals and wait for interrupt
sigsuspend OpenBSD atomically release blocked signals and wait for interrupt
sigsuspend Tru64 Atomically change the set of blocked signals and wait for a signal
sigpause NetBSD atomically release blocked signals and wait for interrupt
Copyright © 2004-2005 DeniX Solutions SRL
newsletter delivery service