The Single UNIX ® Specification, Version 2
Copyright © 1997 The Open Group

 NAME

pthread_kill - send a signal to a thread

 SYNOPSIS



#include <signal.h>

int pthread_kill(pthread_t thread, int sig);

 DESCRIPTION

The pthread_kill() function is used to request that a signal be delivered to the specified thread.

As in kill(), if sig is zero, error checking is performed but no signal is actually sent.

 RETURN VALUE

Upon successful completion, the function returns a value of zero. Otherwise the function returns an error number. If the pthread_kill() function fails, no signal is sent.

 ERRORS

The pthread_kill() function will fail if:
[ESRCH]
No thread could be found corresponding to that specified by the given thread ID.
[EINVAL]
The value of the sig argument is an invalid or unsupported signal number.

The pthread_kill() function will not return an error code of [EINTR].

 EXAMPLES

None.

 APPLICATION USAGE

None.

 FUTURE DIRECTIONS

None.

 SEE ALSO

kill(), pthread_self(), raise(), <signal.h>.

DERIVATION

Derived from the POSIX Threads Extension (1003.1c-1995)

UNIX ® is a registered Trademark of The Open Group.
Copyright © 1997 The Open Group
[ Main Index | XSH | XCU | XBD | XCURSES | XNS ]