LibC: Implement `difftime`
This commit is contained in:
parent
1a38d0c31e
commit
abf7c8e68a
|
@ -38,6 +38,11 @@ time_t time(time_t* tloc)
|
|||
return tp.tv_sec;
|
||||
}
|
||||
|
||||
double difftime(time_t time1, time_t time0)
|
||||
{
|
||||
return time1 - time0;
|
||||
}
|
||||
|
||||
// sample implementation from https://pubs.opengroup.org/onlinepubs/9699919799/functions/asctime.html
|
||||
char* asctime_r(const struct tm* __restrict tm, char* __restrict buf)
|
||||
{
|
||||
|
|
Loading…
Reference in New Issue