repo.or.cz
/
minix.git
/
blob
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
log
|
graphiclog1
|
graphiclog2
|
commit
|
commitdiff
|
tree
|
refs
|
edit
|
fork
blame
|
history
|
raw
|
HEAD
secondary cache feature in vm.
[minix.git]
/
lib
/
libc
/
posix
/
_waitpid.c
blob
ddab2b090596895eadda2485b748e322eec22935
1
#include <lib.h>
2
#define waitpid _waitpid
3
#include <sys/wait.h>
4
5
PUBLIC pid_t
waitpid
(
pid
,
status
,
options
)
6
pid_t pid
;
7
int
*
status
;
8
int
options
;
9
{
10
message m
;
11
12
m
.
m1_i1
=
pid
;
13
m
.
m1_i2
=
options
;
14
if
(
_syscall
(
MM
,
WAITPID
, &
m
) <
0
)
return
(-
1
);
15
if
(
status
!=
0
) *
status
=
m
.
m2_i1
;
16
return
m
.
m_type
;
17
}