.\" Copyright (c) 1994 Mike Battersby .\" .\" Permission is granted to make and distribute verbatim copies of this .\" manual provided the copyright notice and this permission notice are .\" preserved on all copies. .\" .\" Permission is granted to copy and distribute modified versions of this .\" manual under the conditions for verbatim copying, provided that the .\" entire resulting derived work is distributed under the terms of a .\" permission notice identical to this one. .\" .\" Since the Linux kernel and libraries are constantly changing, this .\" manual page may be incorrect or out-of-date. The author(s) assume no .\" responsibility for errors or omissions, or for damages resulting from .\" the use of the information contained herein. The author(s) may not .\" have taken the same level of care in the production of this manual, .\" which is licensed free of charge, as they might when working .\" professionally. .\" .\" Formatted or processed versions of this manual, if unaccompanied by .\" the source, must acknowledge the copyright and authors of this work. .\" .\" Modified by aeb, 960721 .\" 2005-11-21, mtk, added descriptions of sigisemptyset(), sigandset(), .\" and sigorset() .\" 2007-10-26 mdw added wording that a sigset_t must be initialized .\" prior to use .\" .\"WORD: signal set シグナル集合 .\" .\" Japanese Version Copyright (c) 1998 HANATAKA Shinya .\" all rights reserved. .\" Translated 1998-05-24, HANATAKA Shinya .\" Updated 2005-12-05, Akihiro MOTOKI, Catch up to LDP man-pages 2.16 .\" Updated 2008-02-09, Akihiro MOTOKI , LDP v2.77 .\" .TH SIGSETOPS 3 2008-09-01 "Linux" "Linux Programmer's Manual" .\"O .SH NAME .SH 名前 .\"O sigemptyset, sigfillset, sigaddset, sigdelset, sigismember \- POSIX .\"O signal set operations. sigemptyset, sigfillset, sigaddset, sigdelset, sigismember \- POSIX シグナル集合の操作 .\"O .SH SYNOPSIS .SH 書式 .B #include .sp .BI "int sigemptyset(sigset_t *" set ); .sp .BI "int sigfillset(sigset_t *" set ); .sp .BI "int sigaddset(sigset_t *" set ", int " signum ); .sp .BI "int sigdelset(sigset_t *" set ", int " signum ); .sp .BI "int sigismember(const sigset_t *" set ", int " signum ); .sp .in -4n .\"O Feature Test Macro Requirements for glibc (see .\"O .BR feature_test_macros (7)): glibc 向けの機能検査マクロの要件 .RB ( feature_test_macros (7) 参照): .in .sp .ad l .BR sigemptyset (), .BR sigfillset (), .BR sigaddset (), .BR sigdelset (), .BR sigismember (): .RS 4 _POSIX_C_SOURCE\ >=\ 1 || _XOPEN_SOURCE || _POSIX_SOURCE .RE .ad b .\"O .SH DESCRIPTION .SH 説明 .\"O These functions allow the manipulation of POSIX signal sets. これらの関数は POSIX シグナル集合(signal set)を操作するため使用する。 .PP .\"O .BR sigemptyset () .\"O initializes the signal set given by .\"O .I set .\"O to empty, with all signals excluded from the set. .BR sigemptyset () は .I set で与えられたシグナル集合を空に初期化し、シグナルが一つも 含まれていない状態にする。 .PP .\"O .BR sigfillset () .\"O initializes .\"O .I set .\"O to full, including all signals. .BR sigfillset () は .I set で与えられたシグナル集合が全てのシグナルを含むようにする。 .PP .\"O .BR sigaddset () .\"O and .\"O .BR sigdelset () .\"O add and delete respectively signal .\"O .I signum .\"O from .\"O .IR set . .BR sigaddset () と .BR sigdelset () は .I set に .I signum シグナルをそれぞれ加えたり、削除したりする。 .PP .\"O .BR sigismember () .\"O tests whether .\"O .I signum .\"O is a member of .\"O .I set . .BR sigismember () は .I signum が .I set に含まれているかどうかをテストする。 .PP .\"O Objects of type .\"O .I sigset_t .\"O must be initialized by a call to either .\"O .BR sigemptyset () .\"O or .\"O .BR sigfillset () .\"O before being passed to the functions .\"O .BR sigaddset (), .\"O .BR sigdelset () .\"O and .\"O .BR sigismember () .\"O or the additional glibc functions described below .\"O .RB ( sigisemptyset (), .\"O .BR sigandset (), .\"O and .\"O .BR sigorset ()). .\"O The results are undefined if this is not done. .I sigset_t 型のオブジェクトは、関数 .BR sigaddset (), .BR sigdelset (), .BR sigismember () や後述の glibc の追加関数 .RB ( sigisemptyset (), .BR sigandset (), .BR sigorset ()) に渡す前に、 .BR sigemptyset () か .BR sigfillset () を呼び出して初期化しなければならない。 初期化しなかった場合の結果は未定義である。 .\"O .SH "RETURN VALUE" .SH 返り値 .\"O .BR sigemptyset (), .\"O .BR sigfillset (), .\"O .BR sigaddset (), .\"O and .\"O .BR sigdelset () .\"O return 0 on success and \-1 on error. .BR sigemptyset (), .BR sigfillset (), .BR sigaddset (), .BR sigdelset () は成功すれば 0 を、エラーの場合は \-1 を返す。 .PP .\"O .BR sigismember () .\"O returns 1 if .\"O .I signum .\"O is a member of .\"O .IR set , .\"O 0 if .\"O .I signum .\"O is not a member, and \-1 on error. .BR sigismember () は .I signum が .I set に含まれていれば 1 を返し、含まれていなければ 0 を返す。 エラーの場合は \-1 を返す。 .\"O .SH ERRORS .SH エラー .TP .B EINVAL .\"O .I sig .\"O is not a valid signal. .I sig が有効なシグナルではない。 .\"O .SH "CONFORMING TO" .SH 準拠 POSIX.1-2001. .\"O .SH NOTES .\"O .SS Glibc Notes .SH 注意 .SS glibc での注意 .\"O If the .\"O .B _GNU_SOURCE .\"O feature test macro is defined, then \fI\fP .\"O exposes three other functions for manipulating signal .\"O sets. .B _GNU_SOURCE 機能検査マクロが定義されていると、 \fI\fP でシグナル集合を操作する 3つの関数が追加で公開される。 .TP .BI "int sigisemptyset(sigset_t *" set ); .\"O returns 1 if .\"O .I set .\"O contains no signals, and 0 otherwise. .I set にシグナルが一つも含まれていなければ 1 を返し、 それ以外は 0 を返す。 .TP .BI "int sigorset(sigset_t *" dest ", sigset_t *" left \ ", sigset_t *" right ); .\"O places the union of the sets .\"O .I left .\"O and .\"O .I right .\"O in .\"O .IR dest . シグナル集合 .I left と .I left の和集合を .I dest に書き込む。 .TP .BI "int sigandset(sigset_t *" dest ", sigset_t *" left \ ", sigset_t *" right ); .\"O places the intersection of the sets .\"O .I left .\"O and .\"O .I right .\"O in .\"O .IR dest . シグナル集合 .I left と .I left の積集合を .I dest に書き込む。 .PP .\"O .BR sigorset () .\"O and .\"O .BR sigandset () .\"O return 0 on success, and \-1 on failure. .BR sigorset () と .BR sigandset () は成功すると 0 を、失敗すると \-1 を返す。 .PP .\"O These functions are nonstandard (a few other systems provide similar .\"O functions) and their use should be avoided in portable applications. これらの関数は非標準であり、(他にも同様の関数を提供しているシステムも いくつかはあるが) 移植性を考慮したアプリケーションでは使用を避けるべき である。 .\"O .SH "SEE ALSO" .SH 関連項目 .BR sigaction (2), .BR sigpending (2), .BR sigprocmask (2), .BR sigsuspend (2)