OK, I was too sleepy there...

Pointy hat over here!
This commit is contained in:
Poul-Henning Kamp 2003-02-23 13:45:55 +00:00
parent dddb791fa4
commit 5cb3dc8fa3

View File

@ -159,10 +159,12 @@ clock_gettime(struct thread *td, struct clock_gettime_args *uap)
{
struct timespec ats;
if (uap->clock_id != CLOCK_REALTIME)
if (uap->clock_id == CLOCK_REALTIME)
nanotime(&ats);
else if (uap->clock_id != CLOCK_MONOTONIC)
else if (uap->clock_id == CLOCK_MONOTONIC)
nanouptime(&ats);
else
return (EINVAL);
return (copyout(&ats, uap->tp, sizeof(ats)));
}