(pthread_cancel): Don't do anything if cancelation is disabled.
authorUlrich Drepper <drepper@redhat.com>
Thu, 28 Sep 2000 22:46:36 +0000 (22:46 +0000)
committerUlrich Drepper <drepper@redhat.com>
Thu, 28 Sep 2000 22:46:36 +0000 (22:46 +0000)
linuxthreads/cancel.c

index a51e8cc..370a373 100644 (file)
@@ -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;
   }