summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--lib/libc_r/uthread/uthread_cancel.c5
-rw-r--r--lib/libkse/thread/thr_cancel.c5
-rw-r--r--lib/libpthread/thread/thr_cancel.c5
3 files changed, 3 insertions, 12 deletions
diff --git a/lib/libc_r/uthread/uthread_cancel.c b/lib/libc_r/uthread/uthread_cancel.c
index 67c1fb4..4c6ca98 100644
--- a/lib/libc_r/uthread/uthread_cancel.c
+++ b/lib/libc_r/uthread/uthread_cancel.c
@@ -65,14 +65,11 @@ _pthread_cancel(pthread_t pthread)
case PS_JOIN:
/*
- * Disconnect the thread from the joinee and
- * detach:
+ * Disconnect the thread from the joinee:
*/
if (pthread->join_status.thread != NULL) {
pthread->join_status.thread->joiner
= NULL;
- pthread_detach((pthread_t)
- pthread->join_status.thread);
}
pthread->cancelflags |= PTHREAD_CANCELLING;
PTHREAD_NEW_STATE(pthread, PS_RUNNING);
diff --git a/lib/libkse/thread/thr_cancel.c b/lib/libkse/thread/thr_cancel.c
index 67c1fb4..4c6ca98 100644
--- a/lib/libkse/thread/thr_cancel.c
+++ b/lib/libkse/thread/thr_cancel.c
@@ -65,14 +65,11 @@ _pthread_cancel(pthread_t pthread)
case PS_JOIN:
/*
- * Disconnect the thread from the joinee and
- * detach:
+ * Disconnect the thread from the joinee:
*/
if (pthread->join_status.thread != NULL) {
pthread->join_status.thread->joiner
= NULL;
- pthread_detach((pthread_t)
- pthread->join_status.thread);
}
pthread->cancelflags |= PTHREAD_CANCELLING;
PTHREAD_NEW_STATE(pthread, PS_RUNNING);
diff --git a/lib/libpthread/thread/thr_cancel.c b/lib/libpthread/thread/thr_cancel.c
index 67c1fb4..4c6ca98 100644
--- a/lib/libpthread/thread/thr_cancel.c
+++ b/lib/libpthread/thread/thr_cancel.c
@@ -65,14 +65,11 @@ _pthread_cancel(pthread_t pthread)
case PS_JOIN:
/*
- * Disconnect the thread from the joinee and
- * detach:
+ * Disconnect the thread from the joinee:
*/
if (pthread->join_status.thread != NULL) {
pthread->join_status.thread->joiner
= NULL;
- pthread_detach((pthread_t)
- pthread->join_status.thread);
}
pthread->cancelflags |= PTHREAD_CANCELLING;
PTHREAD_NEW_STATE(pthread, PS_RUNNING);
OpenPOWER on IntegriCloud