1 .\" Copyright (c) 1994 Mike Battersby
3 .\" Permission is granted to make and distribute verbatim copies of this
4 .\" manual provided the copyright notice and this permission notice are
5 .\" preserved on all copies.
7 .\" Permission is granted to copy and distribute modified versions of this
8 .\" manual under the conditions for verbatim copying, provided that the
9 .\" entire resulting derived work is distributed under the terms of a
10 .\" permission notice identical to this one.
12 .\" Since the Linux kernel and libraries are constantly changing, this
13 .\" manual page may be incorrect or out-of-date. The author(s) assume no
14 .\" responsibility for errors or omissions, or for damages resulting from
15 .\" the use of the information contained herein. The author(s) may not
16 .\" have taken the same level of care in the production of this manual,
17 .\" which is licensed free of charge, as they might when working
20 .\" Formatted or processed versions of this manual, if unaccompanied by
21 .\" the source, must acknowledge the copyright and authors of this work.
23 .\" Modified by aeb, 960721
24 .\" 2005-11-21, mtk, added descriptions of sigisemptyset(), sigandset(),
26 .\" 2007-10-26 mdw added wording that a sigset_t must be initialized
29 .\"WORD: signal set ¥·¥°¥Ê¥ë½¸¹ç
31 .\" Japanese Version Copyright (c) 1998 HANATAKA Shinya
32 .\" all rights reserved.
33 .\" Translated 1998-05-24, HANATAKA Shinya <hanataka@abyss.rim.or.jp>
34 .\" Updated 2005-12-05, Akihiro MOTOKI, Catch up to LDP man-pages 2.16
35 .\" Updated 2008-02-09, Akihiro MOTOKI <amotoki@dd.iij4u.or.jp>, LDP v2.77
37 .TH SIGSETOPS 3 2008-09-01 "Linux" "Linux Programmer's Manual"
40 .\"O sigemptyset, sigfillset, sigaddset, sigdelset, sigismember \- POSIX
41 .\"O signal set operations.
42 sigemptyset, sigfillset, sigaddset, sigdelset, sigismember \- POSIX
46 .B #include <signal.h>
48 .BI "int sigemptyset(sigset_t *" set );
50 .BI "int sigfillset(sigset_t *" set );
52 .BI "int sigaddset(sigset_t *" set ", int " signum );
54 .BI "int sigdelset(sigset_t *" set ", int " signum );
56 .BI "int sigismember(const sigset_t *" set ", int " signum );
59 .\"O Feature Test Macro Requirements for glibc (see
60 .\"O .BR feature_test_macros (7)):
61 glibc ¸þ¤±¤Îµ¡Ç½¸¡ºº¥Þ¥¯¥í¤ÎÍ×·ï
62 .RB ( feature_test_macros (7)
72 _POSIX_C_SOURCE\ >=\ 1 || _XOPEN_SOURCE || _POSIX_SOURCE
76 .\"O These functions allow the manipulation of POSIX signal sets.
77 ¤³¤ì¤é¤Î´Ø¿ô¤Ï POSIX ¥·¥°¥Ê¥ë½¸¹ç(signal set)¤òÁàºî¤¹¤ë¤¿¤á»ÈÍѤ¹¤ë¡£
79 .\"O .BR sigemptyset ()
80 .\"O initializes the signal set given by
82 .\"O to empty, with all signals excluded from the set.
86 ¤ÇÍ¿¤¨¤é¤ì¤¿¥·¥°¥Ê¥ë½¸¹ç¤ò¶õ¤Ë½é´ü²½¤·¡¢¥·¥°¥Ê¥ë¤¬°ì¤Ä¤â
87 ´Þ¤Þ¤ì¤Æ¤¤¤Ê¤¤¾õÂ֤ˤ¹¤ë¡£
89 .\"O .BR sigfillset ()
92 .\"O to full, including all signals.
96 ¤ÇÍ¿¤¨¤é¤ì¤¿¥·¥°¥Ê¥ë½¸¹ç¤¬Á´¤Æ¤Î¥·¥°¥Ê¥ë¤ò´Þ¤à¤è¤¦¤Ë¤¹¤ë¡£
100 .\"O .BR sigdelset ()
101 .\"O add and delete respectively signal
112 ¥·¥°¥Ê¥ë¤ò¤½¤ì¤¾¤ì²Ã¤¨¤¿¤ê¡¢ºï½ü¤·¤¿¤ê¤¹¤ë¡£
114 .\"O .BR sigismember ()
124 ¤Ë´Þ¤Þ¤ì¤Æ¤¤¤ë¤«¤É¤¦¤«¤ò¥Æ¥¹¥È¤¹¤ë¡£
128 .\"O must be initialized by a call to either
129 .\"O .BR sigemptyset ()
131 .\"O .BR sigfillset ()
132 .\"O before being passed to the functions
133 .\"O .BR sigaddset (),
134 .\"O .BR sigdelset ()
136 .\"O .BR sigismember ()
137 .\"O or the additional glibc functions described below
138 .\"O .RB ( sigisemptyset (),
139 .\"O .BR sigandset (),
141 .\"O .BR sigorset ()).
142 .\"O The results are undefined if this is not done.
144 ·¿¤Î¥ª¥Ö¥¸¥§¥¯¥È¤Ï¡¢´Ø¿ô
148 ¤ä¸å½Ò¤Î glibc ¤ÎÄɲôؿô
149 .RB ( sigisemptyset (),
156 ¤ò¸Æ¤Ó½Ð¤·¤Æ½é´ü²½¤·¤Ê¤±¤ì¤Ð¤Ê¤é¤Ê¤¤¡£
157 ½é´ü²½¤·¤Ê¤«¤Ã¤¿¾ì¹ç¤Î·ë²Ì¤Ï̤ÄêµÁ¤Ç¤¢¤ë¡£
158 .\"O .SH "RETURN VALUE"
160 .\"O .BR sigemptyset (),
161 .\"O .BR sigfillset (),
162 .\"O .BR sigaddset (),
164 .\"O .BR sigdelset ()
165 .\"O return 0 on success and \-1 on error.
170 ¤ÏÀ®¸ù¤¹¤ì¤Ð 0 ¤ò¡¢¥¨¥é¡¼¤Î¾ì¹ç¤Ï \-1 ¤òÊÖ¤¹¡£
172 .\"O .BR sigismember ()
179 .\"O is not a member, and \-1 on error.
185 ¤Ë´Þ¤Þ¤ì¤Æ¤¤¤ì¤Ð 1 ¤òÊÖ¤·¡¢´Þ¤Þ¤ì¤Æ¤¤¤Ê¤±¤ì¤Ð 0 ¤òÊÖ¤¹¡£
186 ¥¨¥é¡¼¤Î¾ì¹ç¤Ï \-1 ¤òÊÖ¤¹¡£
192 .\"O is not a valid signal.
194 ¤¬Í¸ú¤Ê¥·¥°¥Ê¥ë¤Ç¤Ï¤Ê¤¤¡£
195 .\"O .SH "CONFORMING TO"
204 .\"O feature test macro is defined, then \fI<signal.h>\fP
205 .\"O exposes three other functions for manipulating signal
208 µ¡Ç½¸¡ºº¥Þ¥¯¥í¤¬ÄêµÁ¤µ¤ì¤Æ¤¤¤ë¤È¡¢
209 \fI<signal.h>\fP ¤Ç¥·¥°¥Ê¥ë½¸¹ç¤òÁàºî¤¹¤ë 3¤Ä¤Î´Ø¿ô¤¬ÄɲäǸø³«¤µ¤ì¤ë¡£
211 .BI "int sigisemptyset(sigset_t *" set );
214 .\"O contains no signals, and 0 otherwise.
216 ¤Ë¥·¥°¥Ê¥ë¤¬°ì¤Ä¤â´Þ¤Þ¤ì¤Æ¤¤¤Ê¤±¤ì¤Ð 1 ¤òÊÖ¤·¡¢
217 ¤½¤ì°Ê³°¤Ï 0 ¤òÊÖ¤¹¡£
219 .BI "int sigorset(sigset_t *" dest ", sigset_t *" left \
220 ", sigset_t *" right );
221 .\"O places the union of the sets
235 .BI "int sigandset(sigset_t *" dest ", sigset_t *" left \
236 ", sigset_t *" right );
237 .\"O places the intersection of the sets
253 .\"O .BR sigandset ()
254 .\"O return 0 on success, and \-1 on failure.
258 ¤ÏÀ®¸ù¤¹¤ë¤È 0 ¤ò¡¢¼ºÇÔ¤¹¤ë¤È \-1 ¤òÊÖ¤¹¡£
260 .\"O These functions are nonstandard (a few other systems provide similar
261 .\"O functions) and their use should be avoided in portable applications.
262 ¤³¤ì¤é¤Î´Ø¿ô¤ÏÈóɸ½à¤Ç¤¢¤ê¡¢(¾¤Ë¤âƱÍͤδؿô¤òÄ󶡤·¤Æ¤¤¤ë¥·¥¹¥Æ¥à¤â
263 ¤¤¤¯¤Ä¤«¤Ï¤¢¤ë¤¬) °Ü¿¢À¤ò¹Íθ¤·¤¿¥¢¥×¥ê¥±¡¼¥·¥ç¥ó¤Ç¤Ï»ÈÍѤòÈò¤±¤ë¤Ù¤