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:
parent
69b2baeebe
commit
f2ff06c9d4
@ -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 {
|
||||
|
Loading…
Reference in New Issue
Block a user