source:
trunk/minix/lib/other/_getnpid.c@
11
Last change on this file since 11 was 9, checked in by , 14 years ago | |
---|---|
File size: 283 bytes |
Line | |
---|---|
1 | #include <lib.h> |
2 | #define getnpid _getnpid |
3 | #include <unistd.h> |
4 | |
5 | PUBLIC pid_t getnpid(int proc_nr) |
6 | { |
7 | message m; |
8 | m.m1_i1 = proc_nr; /* search pid for this process */ |
9 | if (_syscall(MM, GETPID, &m) < 0) return ( (pid_t) -1); |
10 | return( (pid_t) m.m2_i2); /* return search result */ |
11 | } |
Note:
See TracBrowser
for help on using the repository browser.