PTHREAD_KILL(3) BSD Programmer's Manual PTHREAD_KILL(3)NAMEpthread_kill - send signal to a process
SYNOPSIS
#include <pthread.h>
#include <signal.h>
int
pthread_kill(pthread_t thread, int sig);
DESCRIPTION
The pthread_kill() function sends the signal given by sig to the speci-
fied thread. Sig may be one of the signals specified in sigaction(2) or
it may be 0, in which case error checking is performed but no signal is
actually sent. This can be used to check the validity of thread.
RETURN VALUES
Upon successful completion, a value of 0 is returned. Otherwise, an er-
ror value is returned.
ERRORSPthread_kill() will fail and no signal will be sent if:
[EINVAL] Sig is not a valid signal number.
[ESRCH] No thread can be found corresponding to that specified by
thread.
SEE ALSOkill(2), pthread_sigmask(3)sigaction(2)STANDARDS
The pthread_kill() function is expected to conform to IEEE Std1003.1c
(``POSIX'').
4th Berkeley Distribution June 3, 1996 1