1 .\" Copyright (c) 2003 Andries Brouwer (aeb@cwi.nl)
3 .\" This is free documentation; you can redistribute it and/or
4 .\" modify it under the terms of the GNU General Public License as
5 .\" published by the Free Software Foundation; either version 2 of
6 .\" the License, or (at your option) any later version.
8 .\" The GNU General Public License's references to "object code"
9 .\" and "executables" are to be interpreted as the output of any
10 .\" document formatting or typesetting system, including
11 .\" intermediate and printed output.
13 .\" This manual is distributed in the hope that it will be useful,
14 .\" but WITHOUT ANY WARRANTY; without even the implied warranty of
15 .\" MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
16 .\" GNU General Public License for more details.
18 .\" You should have received a copy of the GNU General Public
19 .\" License along with this manual; if not, write to the Free
20 .\" Software Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111,
23 .\" Japanese Version Copyright (c) 2004 Yuichi SATO
24 .\" all rights reserved.
25 .\" Translated Sat Sep 11 07:32:05 JST 2004
26 .\" by Yuichi SATO <ysato444@yahoo.co.jp>
27 .\" Updated 2007-05-04, Akihiro MOTOKI <amotoki@dd.iij4u.or.jp>
29 .TH UALARM 3 2010-09-20 "" "Linux Programmer's Manual"
32 .\"O ualarm \- schedule signal after given number of microseconds
33 ualarm \- 指定したマイクロ秒後にシグナルを送る予定をする
37 .B "#include <unistd.h>"
39 .BI "useconds_t ualarm(useconds_t " usecs ", useconds_t " interval );
43 .\"O Feature Test Macro Requirements for glibc (see
44 .\"O .BR feature_test_macros (7)):
46 .RB ( feature_test_macros (7)
55 .\"O Since glibc 2.12:
59 (_XOPEN_SOURCE\ >=\ 500 ||
60 _XOPEN_SOURCE\ &&\ _XOPEN_SOURCE_EXTENDED) &&
61 !(_POSIX_C_SOURCE\ >=\ 200809L || _XOPEN_SOURCE\ >=\ 700)
64 .\"O Before glibc 2.12:
66 _BSD_SOURCE || _XOPEN_SOURCE\ >=\ 500 ||
67 _XOPEN_SOURCE\ &&\ _XOPEN_SOURCE_EXTENDED
75 .\"O function causes the signal
77 .\"O to be sent to the invoking process after (not less than)
86 .\"O The delay may be lengthened slightly by any system activity
87 .\"O or by the time spent processing the call or by the
88 .\"O granularity of system timers.
89 遅れはシステムの活性度・呼び出しの処理時間・
90 システムタイマーの粒度によって長くなるかもしれない。
92 .\"O Unless caught or ignored, the
94 .\"O signal will terminate the process.
101 .\"O argument is nonzero, further
103 .\"O signals will be sent every
105 .\"O microseconds after the first.
112 マイクロ秒毎に SIGALRM シグナルが送られる。
113 .\"O .SH "RETURN VALUE"
115 .\"O This function returns the number of microseconds remaining for
116 .\"O any alarm that was previously set, or 0 if no alarm was pending.
117 この関数は、過去に設定された alarm の残りマイクロ秒数を返す。
118 実行中の alarm がない場合は 0 を返す。
123 .\"O Interrupted by a signal.
127 .\"O \fIusecs\fP or \fIinterval\fP is not smaller than 1000000.
128 .\"O (On systems where that is considered an error.)
129 \fIusecs\fP または \fIinterval\fP が 1000000 未満でない
130 (これがエラーとして扱われるシステムの場合)。
131 .\"O .SH "CONFORMING TO"
133 4.3BSD, POSIX.1-2001.
134 .\"O POSIX.1-2001 marks
140 .\"O POSIX.1-2008 removes the specification of
145 .\"O 4.3BSD, SUSv2, and POSIX do not define any errors.
146 4.3BSD, SUSv2, POSIX はエラーを定義していない。
151 .\"O is an unsigned integer type capable of holding integers
152 .\"O in the range [0,1000000].
154 型は [0,1000000] の範囲の整数を保持できる符号なし整数型である。
155 .\"O On the original BSD implementation, and in glibc before version 2.1,
156 .\"O the arguments to
158 .\"O were instead typed as
159 .\"O .IR "unsigned int" .
160 もともとの BSD での実装や、バージョン 2.1 より前の glibc では、
165 .\"O Programs will be more portable if they never mention
172 .\"Osato: mention が訳しづらい。
175 .\"O The interaction of this function with
176 .\"O other timer functions such as
182 .BR timer_create (2),
183 .BR timer_delete (2),
184 .BR timer_getoverrun (2),
185 .BR timer_gettime (2),
186 .BR timer_settime (2),
189 のような他のタイマー関数との相互作用は規定されていない。
191 .\"O This function is obsolete.
193 .\"O .BR setitimer (2)
194 .\"O or POSIX interval timers
195 .\"O .RB ( timer_create (2),
202 .RB ( timer_create (2)