1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145 146 147 148 149 150 151 152 153 154 155 156 157 158 159 160 161 162 163 164 165 166 167 168 169 170 171 172 173 174 175
|
.\" Copyright (c) 2002 Michael Kerrisk <mtk.manpages@gmail.com>
.\"
.\" 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.
.\"
.\" Formatted or processed versions of this manual, if unaccompanied by
.\" the source, must acknowledge the copyright and authors of this work.
.\"
.\" Japanese Version Copyright (c) 2003 Yuichi SATO
.\" all rights reserved.
.\" Translated 2003-02-16, Yuichi SATO <ysato444@yahoo.co.jp>
.\" Updated 2006-07-21, Akihiro MOTOKI <amotoki@dd.iij4u.or.jp>, LDP v2.36
.\"
.\"WORD: pending ԵǤ
.\"
.TH SIGWAITINFO 2 2007-07-26 "Linux" "Linux Programmer's Manual"
.SH ̾
sigwaitinfo, sigtimedwait \- 塼줿ʥƱԤ
.SH
.nf
.B #include <signal.h>
.sp
.BI "int sigwaitinfo(const sigset_t *" set ", siginfo_t *" info ");"
.sp
.BI "int sigtimedwait(const sigset_t *" set ", siginfo_t *" info ", "
.BI " const struct timespec *" timeout ");"
.fi
.sp
.in -4n
glibc εǽޥ
.RB ( feature_test_macros (7)
):
.in
.sp
.BR sigwaitinfo (),
.BR sigtimedwait ():
_POSIX_C_SOURCE\ >=\ 199309L
.SH
.BR sigwaitinfo ()
.I set
ΤΤɤ줫Υʥ뤬ޤǡ
ƤӽФץμ¹Ԥߤ
(ƤӽФץФ
.I set
ΤΤɤ줫Υʥ뤬Ե (pending) Ǥ硢
.BR sigwaitinfo ()
ϤΥʥξ֤Ƥ)
.PP
.BR sigwaitinfo ()
줿ʥƤӽФץ
ԵΥʥΥꥹȤ
ؿη̤Ȥƥʥֹ֤
.I info
NULL Ǥʤ硢줿ʥξä
.I siginfo_t
.RB ( sigaction (2)
) ι¤Τ֤
.PP
.BR sigwaitinfo ()
֤륷ʥϡ̾ν֤롣
ܺ٤
.BR signal (7)
Ȥ뤳ȡ
.PP
.BR sigtimedwait ()
ϡ
.BR sigwaitinfo ()
ȼƱ褦ư롣
δؿˤϤ⤦ 1 Ĥΰ
.I timeout
ꡢץߤ֤ξ¤뤳ȤǤ롣
ΰηϰʲΤȤǤ:
.sp
.in +4n
.nf
struct timespec {
long tv_sec; /* */
long tv_nsec; /* ʥ */
}
.fi
.in
.sp
ι¤Τ 2 ĤΥեɤȤ 0 ξ硢ݡԤ:
.BR sigtimedwait ()
ϡƤӽФ¦ץФ
ԵƤ륷ʥξ֤뤫
.I set
ΤΤɤΥʥԵƤʤϥ顼֤롣
.SH ֤
硢
.BR sigwaitinfo ()
.BR sigtimedwait ()
ϥʥֹ (ʤ 0 礭) ֤
Ԥ硢2 Ĥδؿ \-1 ֤
.I errno
ϥ顼ɽͤꤵ롣
.SH 顼
.TP
.B EAGAIN
.I set
ΤΤɤΥʥ
.BR sigtimedwait ()
˻ꤵ줿
.I timeout
δʤä
.TP
.B EINTR
ʥԤʥϥɥˤä (interrupt) 줿
(Υϥɥ
.I set
ˤ륷ʥʳΤΤǤ)
.TP
.B EINVAL
.I timeout
Ǥ롣
.SH
POSIX.1-2001
.SH
̾λˡǤϡƤӽФ¦ץϤδؿ
.BR sigprocmask (2)
θƤӽФȤˤ
.I set
˴ޤޤ륷ʥ֥å
(ΤˤΥʥ뤬θ³
.BR sigwaitinfo ()
.BR sigtimedwait ()
θƤӽФδ֤줿ˤϡ
ǥեȤ֤ϹԤ줺)
ΥʥФϥɥꤷʤ
ޥåɥץǤϡ
.BR sigwaitinfo ()
.BR sigtimedwait ()
ƤӽФåɰʳΥåɤˤΥʥ뤬ʤ褦ˡ
ƤΥåɤdzʥ֥å٤Ǥ롣
.PP
POSIX Ǥ
.BR sigtimedwait ()
ΰ
.I timeout
ͤ NULL ˤΰ̣̤ȤƤ롣
.BR sigwaitinfo ()
ƤӽФΤƱ̣ȤƤ褤ȤˤʤäƤꡢ
º Linux ǤϤΤ褦ư롣
Linux Ǥϡ
.BR sigwaitinfo ()
.BR sigtimedwait ()
ѤƼ줿饤֥ؿǤ롣
.SH Ϣ
.BR kill (2),
.BR sigaction (2),
.BR signal (2),
.BR signalfd (2),
.BR sigpending (2),
.BR sigprocmask (2),
.BR sigqueue (2),
.BR sigsetops (3),
.BR signal (7)
|