summaryrefslogtreecommitdiffstats
path: root/lib/libc_r/uthread/uthread_suspend_np.c
diff options
context:
space:
mode:
Diffstat (limited to 'lib/libc_r/uthread/uthread_suspend_np.c')
-rw-r--r--lib/libc_r/uthread/uthread_suspend_np.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/lib/libc_r/uthread/uthread_suspend_np.c b/lib/libc_r/uthread/uthread_suspend_np.c
index fb90c1d..d065b73 100644
--- a/lib/libc_r/uthread/uthread_suspend_np.c
+++ b/lib/libc_r/uthread/uthread_suspend_np.c
@@ -53,14 +53,14 @@ pthread_suspend_np(pthread_t thread)
_thread_seterrno(pthread,EINTR);
}
/* Suspend the thread. */
- pthread->state = PS_SUSPENDED;
+ PTHREAD_NEW_STATE(pthread,PS_SUSPENDED);
ret = 0;
}
}
/* Check if thread was not found. */
if (ret == -1) {
/* No such thread */
- _thread_seterrno(_thread_run,ESRCH);
+ errno = ESRCH;
}
return(ret);
}
OpenPOWER on IntegriCloud