OSDN Git Service

Import translated manuals from JM CVS Repository.
[linuxjm/jm.git] / manual / LDP_man-pages / release / man2 / wait4.2
1 .\" Hey Emacs! This file is -*- nroff -*- source.
2 .\"
3 .\" Copyright (c) 1993 by Thomas Koenig (ig25@rz.uni-karlsruhe.de)
4 .\" and Copyright (c) 2004 by Michael Kerrisk (mtk.manpages@gmail.com)
5 .\"
6 .\" Permission is granted to make and distribute verbatim copies of this
7 .\" manual provided the copyright notice and this permission notice are
8 .\" preserved on all copies.
9 .\"
10 .\" Permission is granted to copy and distribute modified versions of this
11 .\" manual under the conditions for verbatim copying, provided that the
12 .\" entire resulting derived work is distributed under the terms of a
13 .\" permission notice identical to this one.
14 .\"
15 .\" Since the Linux kernel and libraries are constantly changing, this
16 .\" manual page may be incorrect or out-of-date.  The author(s) assume no
17 .\" responsibility for errors or omissions, or for damages resulting from
18 .\" the use of the information contained herein.  The author(s) may not
19 .\" have taken the same level of care in the production of this manual,
20 .\" which is licensed free of charge, as they might when working
21 .\" professionally.
22 .\"
23 .\" Formatted or processed versions of this manual, if unaccompanied by
24 .\" the source, must acknowledge the copyright and authors of this work.
25 .\" License.
26 .\"
27 .\" Modified Sat Jul 24 13:32:44 1993 by Rik Faith (faith@cs.unc.edu)
28 .\" Modified Mon Jun 23 14:09:52 1997 by aeb - add EINTR.
29 .\" Modified Tue Jul  7 12:26:42 1998 by aeb - changed return value wait3
30 .\" Modified 2004-11-11, Michael Kerrisk <mtk.manpages@gmail.com>
31 .\"     Rewrote much of this page, and removed much duplicated text,
32 .\"             replacing with pointers to wait.2
33 .\"
34 .\" Japanese Version Copyright (c) 1997,1998 HANATAKA Shinya
35 .\"         all rights reserved.
36 .\" Translated 1997-03-04, HANATAKA Shinya <hanataka@abyss.rim.or.jp>
37 .\" Modified 1997-09-28, HANATAKA Shinya <hanataka@abyss.rim.or.jp>
38 .\" Modified 2001-08-17, HANATAKA Shinya <hanataka@abyss.rim.or.jp>
39 .\" Updated 2001-12-13, Kentaro Shirakata <argrath@ub32.org>
40 .\" Updated 2003-09-12, Kentaro Shirakata <argrath@ub32.org>
41 .\" Updated 2005-03-04, Akihiro MOTOKI <amotoki@dd.iij4u.or.jp>
42 .\"
43 .\"WORD:        signal handling         ¥·¥°¥Ê¥ë½èÍý
44 .\"WORD:        suspend                 Ää»ß(suspend)
45 .\"WORD:        zombie                  ¥¾¥ó¥Ó(zombie)
46 .\"WORD:        child process           »Ò¥×¥í¥»¥¹
47 .\"WORD:        process group           ¥×¥í¥»¥¹¡¦¥°¥ë¡¼¥×
48 .\"WORD:        process group ID        ¥×¥í¥»¥¹¡¦¥°¥ë¡¼¥×ID
49 .\"WORD:        stop                    Ää»ß(stop)
50 .\"WORD:        effective user ID       ¼Â¸ú¥æ¡¼¥¶¡¼ID
51 .\"WORD:        block                   ¶Ø»ß(block)
52 .\"WORD:        catch                   Êá³Í(catch)
53 .\"WORD:        account                 ¥¢¥«¥¦¥ó¥È
54 .\"
55 .TH WAIT4 2  2008-09-28 "Linux" "Linux Programmer's Manual"
56 .SH Ì¾Á°
57 wait3, wait4 \- BSD ¥¹¥¿¥¤¥ë¤Ç¥×¥í¥»¥¹¤Î¾õÂÖÊѲ½¤òÂÔ¤Ä
58 .SH ½ñ¼°
59 .nf
60 .B #include <sys/types.h>
61 .B #include <sys/time.h>
62 .B #include <sys/resource.h>
63 .B #include <sys/wait.h>
64 .sp
65 .BI "pid_t wait3(int *" "status" ", int " options ,
66 .BI "            struct rusage *" rusage );
67 .sp
68 .BI "pid_t wait4(pid_t " pid ", int *" status ", int " options ,
69 .BI "            struct rusage *" rusage );
70 .fi
71 .sp
72 .in -4n
73 glibc ¸þ¤±¤Îµ¡Ç½¸¡ºº¥Þ¥¯¥í¤ÎÍ×·ï
74 .RB ( feature_test_macros (7)
75 »²¾È):
76 .in
77 .sp
78 .BR wait3 ():
79 _BSD_SOURCE
80 .br
81 .BR wait4 ():
82 _BSD_SOURCE || _XOPEN_SOURCE\ >=\ 500
83 .SH ÀâÌÀ
84 ¥·¥¹¥Æ¥à¥³¡¼¥ë
85 .BR wait3 ()
86 ¤È
87 .BR wait4 ()
88 ¤Ï
89 .BR waitpid (2)
90 ¤ÈƱÍͤÎÆ°ºî¤ò¤¹¤ë¡£¤½¤ì¤Ë²Ã¤¨¡¢»Ò¥×¥í¥»¥¹¤Î¥ê¥½¡¼¥¹»ÈÍѾõ¶·¤Î¾ðÊó¤ò
91 .I rusage
92 ¤¬»Ø¤¹¹½Â¤ÂΤËÆþ¤ì¤ÆÊÖ¤¹¡£
93 .PP
94 .I rusage
95 ¤ò»ÈÍѤ¹¤ëÅÀ¤ò½ü¤±¤Ð¡¢°Ê²¼¤Î 2¤Ä¤ÏÅù²Á¤Ç¤¢¤ë¡£
96 .nf
97
98     wait3(status, options, rusage);
99
100     waitpid(\-1, status, options);
101
102 .fi
103 ƱÍͤˡ¢°Ê²¼¤Î 2¤Ä¤âÅù²Á¤Ç¤¢¤ë¡£
104 .nf
105
106     wait4(pid, status, options, rusage);
107
108     waitpid(pid, status, options);
109
110 .fi
111 ¸À¤¤´¹¤¨¤ë¤È¡¢
112 .BR wait3 ()
113 ¤ÏÁ´¤Æ¤Î»Ò¥×¥í¥»¥¹¤òÂоݤËÂԤĤ¬¡¢
114 .BR wait4 ()
115 ¤Ç¤ÏÆÃÄê¤Î»Ò¥×¥í¥»¥¹ (Ê£¿ô²Ä) ¤òÁª¤ó¤ÇÂԤĤ³¤È¤¬¤Ç¤­¤ë¡£
116 .PP
117 .I rusage
118 ¤¬ NULL ¤Ç¤Ê¤¤¾ì¹ç¡¢
119 .I rusage
120 ¤¬»Ø¤¹
121 .I rusage ¹½Â¤ÂÎ
122 ¤Ë¤Ï»Ò¥×¥í¥»¥¹¤Î¥¢¥«¥¦¥ó¥È¾ðÊ󤬳ÊǼ¤µ¤ì¤ë¡£
123 ¾Ü¤·¤¯¤Ï
124 .BR getrusage (2)
125 ¤ò»²¾È¤Î¤³¤È¡£
126 .SH ÊÖ¤êÃÍ
127 .BR waitpid (2)
128 ¤ÈƱÍÍ¡£
129 .SH ¥¨¥é¡¼
130 .BR waitpid (2)
131 ¤ÈƱÍÍ¡£
132 .SH ½àµò
133 4.3BSD.
134 .SH Ãí°Õ
135 ¸½ºß¤Ç¤Ï
136 .I <sys/time.h>
137 ¤ò¥¤¥ó¥¯¥ë¡¼¥É¤¹¤ëɬÍפϤʤ¤¤¬¡¢¥¤¥ó¥¯¥ë¡¼¥É¤·¤Æ¤ª¤¯¤È
138 °Ü¿¢À­¤ò¹â¤á¤ë¤³¤È¤¬¤Ç¤­¤ë (¼ÂºÝ¤Ë¤Ï
139 .I <sys/resource.h>
140 ¤Ç
141 .I rusage
142 ¹½Â¤ÂΤ¬ÄêµÁ¤µ¤ì¤Æ¤¤¤ë¤¬¡¢¤½¤Î¥Õ¥£¡¼¥ë¥É¤Ç»ÈÍѤµ¤ì¤Æ¤¤¤ë
143 .I struct timeval
144 ·¿¤Ï
145 .I <sys/time.h>
146 ¤ÇÄêµÁ¤µ¤ì¤Æ¤¤¤ë)¡£
147
148 Linux ¤Ç¤Ï¡¢
149 .BR wait3 ()
150 ¤Ï¥é¥¤¥Ö¥é¥ê´Ø¿ô¤Ç¤¢¤ê¡¢
151 .BR wait4 ()
152 ¥·¥¹¥Æ¥à¥³¡¼¥ë¤ò»È¤Ã¤Æ¼ÂÁõ¤µ¤ì¤Æ¤¤¤ë¡£
153 .SH ´ØÏ¢¹àÌÜ
154 .BR fork (2),
155 .BR getrusage (2),
156 .BR sigaction (2),
157 .BR signal (2),
158 .BR wait (2),
159 .BR signal (7)