Cygwin: Cleanup time handling
* Redefine NSPERSEC to NS100PERSEC * Define NSPERSEC as nanosecs per second * Define USPERSEC as microsecs per second * Use above constants throughout where appropriate * Rename to_us to timespec_to_us and inline * Rename it_bad to timespec_bad and inline Signed-off-by: Corinna Vinschen <corinna@vinschen.de>
This commit is contained in:
@@ -183,7 +183,7 @@ ipc_cond_timedwait (HANDLE evt, HANDLE mtx, const struct timespec *abstime)
|
||||
{
|
||||
if (abstime->tv_sec < 0
|
||||
|| abstime->tv_nsec < 0
|
||||
|| abstime->tv_nsec > 999999999)
|
||||
|| abstime->tv_nsec >= NSPERSEC)
|
||||
return EINVAL;
|
||||
|
||||
/* If a timeout is set, we create a waitable timer to wait for.
|
||||
|
Reference in New Issue
Block a user