From 2da28d2bee8640eb5563ca4f086117a8ac300093 Mon Sep 17 00:00:00 2001 From: Alexander Krutwig Date: Tue, 31 Mar 2015 15:14:28 +0200 Subject: psxtmtests: Use timeout in more distant future Adds future compatibility with strict monontonic software timestamps. --- testsuites/psxtmtests/psxtmcond08/init.c | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) (limited to 'testsuites/psxtmtests') diff --git a/testsuites/psxtmtests/psxtmcond08/init.c b/testsuites/psxtmtests/psxtmcond08/init.c index 8af9f9dbfc..2224f230ba 100644 --- a/testsuites/psxtmtests/psxtmcond08/init.c +++ b/testsuites/psxtmtests/psxtmcond08/init.c @@ -85,7 +85,9 @@ void *Middle( rtems_test_assert( rc == 0 ); #elif defined(USE_TIMEDWAIT_WITH_VALUE) - + /* adjust sleepTime to get something obviously in the future */ + ++sleepTime.tv_sec; + rc = pthread_cond_timedwait( &CondID, &MutexID, &sleepTime ); rtems_test_assert( rc == 0 ); @@ -133,7 +135,6 @@ void *POSIX_Init( /* Convert from timeval to timespec */ sleepTime.tv_sec = tp.tv_sec; sleepTime.tv_nsec = tp.tv_usec * 1000; - sleepTime.tv_nsec += 1; rc = pthread_cond_init(&CondID, NULL); rtems_test_assert( rc == 0 ); -- cgit v1.2.3