mirror of
https://sourceware.org/git/glibc.git
synced 2024-11-22 13:00:06 +00:00
(pthread_cancel): Use the result of __pthread_kill.
This commit is contained in:
parent
b0104b6f8d
commit
e9cb48ab58
@ -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;
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user