source:
trunk/minix/lib/posix/_times.c@
16
Last change on this file since 16 was 9, checked in by , 14 years ago | |
---|---|
File size: 388 bytes |
Rev | Line | |
---|---|---|
[9] | 1 | #include <lib.h> |
2 | #define times _times | |
3 | #include <sys/times.h> | |
4 | #include <time.h> | |
5 | ||
6 | PUBLIC clock_t times(buf) | |
7 | struct tms *buf; | |
8 | { | |
9 | message m; | |
10 | ||
11 | m.m4_l5 = 0; /* return this if system is pre-1.6 */ | |
12 | if (_syscall(MM, TIMES, &m) < 0) return( (clock_t) -1); | |
13 | buf->tms_utime = m.m4_l1; | |
14 | buf->tms_stime = m.m4_l2; | |
15 | buf->tms_cutime = m.m4_l3; | |
16 | buf->tms_cstime = m.m4_l4; | |
17 | return(m.m4_l5); | |
18 | } |
Note:
See TracBrowser
for help on using the repository browser.