summaryrefslogtreecommitdiffstats
path: root/lib/libthr/thread/thr_suspend_np.c
diff options
context:
space:
mode:
Diffstat (limited to 'lib/libthr/thread/thr_suspend_np.c')
-rw-r--r--lib/libthr/thread/thr_suspend_np.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/lib/libthr/thread/thr_suspend_np.c b/lib/libthr/thread/thr_suspend_np.c
index cc424f9..7dbe539 100644
--- a/lib/libthr/thread/thr_suspend_np.c
+++ b/lib/libthr/thread/thr_suspend_np.c
@@ -126,10 +126,10 @@ suspend_common(struct pthread *curthread, struct pthread *thread,
while (thread->state != PS_DEAD &&
!(thread->flags & THR_FLAGS_SUSPENDED)) {
thread->flags |= THR_FLAGS_NEED_SUSPEND;
+ tmp = thread->cycle;
THR_THREAD_UNLOCK(curthread, thread);
_thr_send_sig(thread, SIGCANCEL);
if (waitok) {
- tmp = thread->cycle;
_thr_umtx_wait(&thread->cycle, tmp, NULL);
THR_THREAD_LOCK(curthread, thread);
} else {
OpenPOWER on IntegriCloud