pthread_cancel(3P)
pthread_cancel - request cancellation of a thread
As shipped in IRIX 6.5.22. Unchanged since IRIX 6.5.
NAME pthread_cancel - request cancellation of a thread C SYNOPSIS #include <pthread.h> int pthread_cancel(pthread_t thread); DESCRIPTION The pthread_cancel() function requests that the thread identified by thread be cancelled. Cancellation state [see pthread_setcancelstate()] and type [see pthread_setcanceltype()] determine whether the request is acted upon immediately or at some time in the future; pthread_cancel() does not wait, it merely issues the request. When thread does act on the request, it will terminate as if it had called pthread_exit() with a return status of PTHREAD_CANCELED. DIAGNOSTICS On success pthread_cancel() returns zero; otherwise an error number is returned: [ESRCH] The thread parameter does not identify a thread. SEE ALSO pthread_setcancelstate(3P), pthread_setcanceltype(3P), pthread_exit(3P).