source: trunk/minix/lib/posix/_waitpid.c@ 22

Last change on this file since 22 was 9, checked in by Mattia Monga, 14 years ago

Minix 3.1.2a

File size: 307 bytes
Line 
1#include <lib.h>
2#define waitpid _waitpid
3#include <sys/wait.h>
4
5PUBLIC pid_t waitpid(pid, status, options)
6pid_t pid;
7int *status;
8int 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}
Note: See TracBrowser for help on using the repository browser.