diff options
| author | Daniel Eischen <deischen@FreeBSD.org> | 2003-05-16 19:58:30 +0000 |
|---|---|---|
| committer | Daniel Eischen <deischen@FreeBSD.org> | 2003-05-16 19:58:30 +0000 |
| commit | fd626336fd97bad05a86f02b646c66d2fe14d01a (patch) | |
| tree | b51a83e5c85ef7655ee05174c31348fd86fe4591 /lib/libpthread/thread/thr_nanosleep.c | |
| parent | 72a3951459cd8937c6b6f0b43804c39889c4ae30 (diff) | |
Notes
Diffstat (limited to 'lib/libpthread/thread/thr_nanosleep.c')
| -rw-r--r-- | lib/libpthread/thread/thr_nanosleep.c | 4 |
1 files changed, 1 insertions, 3 deletions
diff --git a/lib/libpthread/thread/thr_nanosleep.c b/lib/libpthread/thread/thr_nanosleep.c index e83f4f4c0370..7266286cbeb3 100644 --- a/lib/libpthread/thread/thr_nanosleep.c +++ b/lib/libpthread/thread/thr_nanosleep.c @@ -62,12 +62,10 @@ _nanosleep(const struct timespec *time_to_sleep, THR_LOCK_SWITCH(curthread); curthread->interrupted = 0; - THR_SET_STATE(curthread, PS_SLEEP_WAIT); /* Reschedule the current thread to sleep: */ - _thr_sched_switch(curthread); - THR_UNLOCK_SWITCH(curthread); + _thr_sched_switch_unlocked(curthread); /* Calculate the remaining time to sleep: */ KSE_GET_TOD(curthread->kse, &ts1); |
