round-up non-zero nanoseconds in #ifdef'ed code.

This commit is contained in:
Peter Wemm 1997-05-17 15:41:08 +00:00
parent eac9eb60ad
commit 7bf1f2c9fa

View File

@ -69,6 +69,8 @@ sleep(seconds)
time_to_sleep.tv_nsec = 0;
nanosleep(&time_to_sleep, &time_remaining);
seconds = time_remaining.tv_sec;
if (time_remaining.tv_nsec > 0)
seconds++; /* round up */
}
return (seconds);
#else