1
0
mirror of https://github.com/RIOT-OS/RIOT.git synced 2024-12-29 04:50:03 +01:00

posix/pthread_rwlock: fix unsigned variable comparison

This commit is contained in:
Jose Alamos 2018-08-21 13:58:39 +02:00
parent 69b2baeebe
commit f2ff06c9d4

View File

@ -191,7 +191,7 @@ static int pthread_rwlock_timedlock(pthread_rwlock_t *rwlock,
uint64_t then = ((uint64_t)abstime->tv_sec * US_PER_SEC) +
(abstime->tv_nsec / NS_PER_US);
if ((then - now) <= 0) {
if (now >= then) {
return ETIMEDOUT;
}
else {