1 .\" Copyright (c) 1994 Mike Battersby
3 .\" %%%LICENSE_START(VERBATIM)
4 .\" Permission is granted to make and distribute verbatim copies of this
5 .\" manual provided the copyright notice and this permission notice are
6 .\" preserved on all copies.
8 .\" Permission is granted to copy and distribute modified versions of this
9 .\" manual under the conditions for verbatim copying, provided that the
10 .\" entire resulting derived work is distributed under the terms of a
11 .\" permission notice identical to this one.
13 .\" Since the Linux kernel and libraries are constantly changing, this
14 .\" manual page may be incorrect or out-of-date. The author(s) assume no
15 .\" responsibility for errors or omissions, or for damages resulting from
16 .\" the use of the information contained herein. The author(s) may not
17 .\" have taken the same level of care in the production of this manual,
18 .\" which is licensed free of charge, as they might when working
21 .\" Formatted or processed versions of this manual, if unaccompanied by
22 .\" the source, must acknowledge the copyright and authors of this work.
25 .\" Modified by aeb, 960721
26 .\" 2005-11-21, mtk, added descriptions of sigisemptyset(), sigandset(),
28 .\" 2007-10-26 mdw added wording that a sigset_t must be initialized
31 .TH SIGSETOPS 3 2014-04-14 "Linux" "Linux Programmer's Manual"
33 sigemptyset, sigfillset, sigaddset, sigdelset, sigismember \- POSIX
36 .B #include <signal.h>
38 .BI "int sigemptyset(sigset_t *" set );
40 .BI "int sigfillset(sigset_t *" set );
42 .BI "int sigaddset(sigset_t *" set ", int " signum );
44 .BI "int sigdelset(sigset_t *" set ", int " signum );
46 .BI "int sigismember(const sigset_t *" set ", int " signum );
49 Feature Test Macro Requirements for glibc (see
50 .BR feature_test_macros (7)):
60 _POSIX_C_SOURCE\ >=\ 1 || _XOPEN_SOURCE || _POSIX_SOURCE
64 These functions allow the manipulation of POSIX signal sets.
67 initializes the signal set given by
69 to empty, with all signals excluded from the set.
74 to full, including all signals.
79 add and delete respectively signal
92 must be initialized by a call to either
96 before being passed to the functions
101 or the additional glibc functions described below
102 .RB ( sigisemptyset (),
106 The results are undefined if this is not done.
113 return 0 on success and \-1 on error.
122 is not a member, and \-1 on error.
124 On error, these functions set
126 to indicate the cause of the error.
131 is not a valid signal.
133 .SS Multithreading (see pthreads(7))
140 .BR sigisemptyset (),
144 functions are thread-safe.
151 feature test macro is defined, then \fI<signal.h>\fP
152 exposes three other functions for manipulating signal
156 .BI "int sigisemptyset(const sigset_t *" set );
157 .BI "int sigorset(sigset_t *" dest ", const sigset_t *" left ,
158 .BI " const sigset_t *" right );
159 .BI "int sigandset(sigset_t *" dest ", const sigset_t *" left ,
160 .BI " const sigset_t *" right );
166 contains no signals, and 0 otherwise.
169 places the union of the sets
176 places the intersection of the sets
182 Both functions return 0 on success, and \-1 on failure.
184 These functions are nonstandard (a few other systems provide similar
185 functions) and their use should be avoided in portable applications.
192 This page is part of release 3.79 of the Linux
195 A description of the project,
196 information about reporting bugs,
197 and the latest version of this page,
199 \%http://www.kernel.org/doc/man\-pages/.