about summary refs log tree commit diff
path: root/linuxthreads
diff options
context:
space:
mode:
Diffstat (limited to 'linuxthreads')
-rw-r--r--linuxthreads/cancel.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/linuxthreads/cancel.c b/linuxthreads/cancel.c
index a51e8ccfc3..370a373c77 100644
--- a/linuxthreads/cancel.c
+++ b/linuxthreads/cancel.c
@@ -64,7 +64,7 @@ int pthread_cancel(pthread_t thread)
 
   th = handle->h_descr;
 
-  if (th->p_canceled) {
+  if (th->p_cancelstate == PTHREAD_CANCEL_DISABLE || th->p_canceled) {
     __pthread_unlock(&handle->h_lock);
     return 0;
   }