time.c (324B)
1/* 2 time.c 3 Simple, not completely conformant implementation of time routines 4*/ 5 6#include <stdint.h> 7 8/* clock() is in clock.s */ 9#include <time.h> 10 11time_t time(time_t *t) { 12 uint16_t ret; 13 /* Should be relative to 0:00 1970 GMT but hey */ 14 ret = clock() / CLOCKS_PER_SEC; 15 if (t) *t = ret; 16 return ret; 17}