September 2008
Intermediate to advanced
647 pages
16h 4m
English
pthread_self — get the calling thread ID
THR #include <pthread.h>
pthread_t pthread_self(void);The pthread_self() function shall return the thread ID of the calling thread.
Refer to the DESCRIPTION.
No errors are defined.
The pthread_self() function shall not return an error code of [EINTR].
None.
None.
The pthread_self() function provides a capability similar to the getpid() function for processes and the rationale is the same: the cretion call does not provide the thread ID to the created thread.
None.
pthread_create(), pthread_equal(), the Base Definitions volume of IEEE Std 1003.1-2001, <pthread.h>
First released in Issue 5. Included for alignment with the POSIX Threads Extension.
The pthread_self() function is marked as part of the Threads option.
Read now
Unlock full access