about summary refs log tree commit diff
path: root/nptl
diff options
context:
space:
mode:
authorUlrich Drepper <drepper@redhat.com>2003-02-16 08:52:22 +0000
committerUlrich Drepper <drepper@redhat.com>2003-02-16 08:52:22 +0000
commite9cb48ab58fd8f619f5c7f13c2188161dbdef254 (patch)
tree9415da212fcae043d2fac9ed28db3dcb750d588b /nptl
parentb0104b6f8d369692d0ca8f265b631a87df7eaeed (diff)
downloadglibc-e9cb48ab58fd8f619f5c7f13c2188161dbdef254.tar.gz
glibc-e9cb48ab58fd8f619f5c7f13c2188161dbdef254.tar.xz
glibc-e9cb48ab58fd8f619f5c7f13c2188161dbdef254.zip
(pthread_cancel): Use the result of __pthread_kill.
Diffstat (limited to 'nptl')
-rw-r--r--nptl/pthread_cancel.c5
1 files changed, 3 insertions, 2 deletions
diff --git a/nptl/pthread_cancel.c b/nptl/pthread_cancel.c
index 0dd97a27e5..153cb198d8 100644
--- a/nptl/pthread_cancel.c
+++ b/nptl/pthread_cancel.c
@@ -27,6 +27,7 @@ pthread_cancel (th)
      pthread_t th;
 {
   volatile struct pthread *pd = (volatile struct pthread *) th;
+  int result = 0;
 
   while (1)
     {
@@ -49,7 +50,7 @@ pthread_cancel (th)
 
 	  /* The cancellation handler will take care of marking the
 	     thread as canceled.  */
-	  __pthread_kill (th, SIGCANCEL);
+	  result = __pthread_kill (th, SIGCANCEL);
 
 	  break;
 	}
@@ -61,5 +62,5 @@ pthread_cancel (th)
 	break;
     }
 
-  return 0;
+  return result;
 }