PTHREAD_SELF(3P) SysV PTHREAD_SELF(3P)
NAME
pthread_self - Returns the ID of the calling thread
SYNOPSIS
#include <pthread.h>
pthread_t pthread_self(void);
DESCRIPTION
The pthread_self function returns the thread ID of the calling thread.
You can use the returned thread ID to pass as the thread argument to
other thread calls.
NOTES
This interface is based on draft 4 of the IEEE P1003.4a standard, and
will be changed to conform to the final version.
DIAGNOSTICS
Upon successful completion, the pthread_self() function returns the
thread ID of the calling thread.
SEE ALSO
pthread_create(3P)