summaryrefslogtreecommitdiff
path: root/regress/lib
diff options
context:
space:
mode:
authorPhilip Guenther <guenther@cvs.openbsd.org>2014-01-22 04:31:46 +0000
committerPhilip Guenther <guenther@cvs.openbsd.org>2014-01-22 04:31:46 +0000
commit336f07576ea188a8b5f11def356ea021868c0b06 (patch)
tree71deb414f0bba854fc9e6be76ab8e3ea43134ed5 /regress/lib
parent65a7c7124e0631f1450e10371fd860243b2dd3fa (diff)
There can be resolution-worth of slop in two places, so accept that
Diffstat (limited to 'regress/lib')
-rw-r--r--regress/lib/libpthread/semaphore/sem_timedwait/sem_timedwait.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/regress/lib/libpthread/semaphore/sem_timedwait/sem_timedwait.c b/regress/lib/libpthread/semaphore/sem_timedwait/sem_timedwait.c
index 38e0ebe18c7..13a1d34a181 100644
--- a/regress/lib/libpthread/semaphore/sem_timedwait/sem_timedwait.c
+++ b/regress/lib/libpthread/semaphore/sem_timedwait/sem_timedwait.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: sem_timedwait.c,v 1.1 2012/03/03 11:08:12 guenther Exp $ */
+/* $OpenBSD: sem_timedwait.c,v 1.2 2014/01/22 04:31:45 guenther Exp $ */
/*
* Martin Pieuchot <mpi@openbsd.org>, 2011. Public Domain.
*/
@@ -81,6 +81,7 @@ main(int argc, char **argv)
else
timespecsub(&ts, &ts2, &ts);
CHECKr(clock_getres(CLOCK_REALTIME, &ts2));
+ timespecadd(&ts2, &ts2, &ts2); /* 2 * resolution slop */
ASSERT(timespeccmp(&ts, &ts2, < ));
CHECKe(sem_destroy(&sem));