Returns the sequence number of a thread.
Threads Library (libpthreads.a)
The pthread_getunique_np subroutine returns the sequence number of the thread thread. The sequence number is a number, unique to each thread, associated with the thread at creation time.
This subroutine is not POSIX compliant and is provided only for compatibility with DCE threads. It should not be used when writing new applications.
Item | Description |
---|---|
thread | Specifies the thread. |
sequence | Points to where the sequence number will be stored. |
Upon successful completion, the sequence number is returned via the sequence parameter, and 0 is returned. Otherwise, an error code is returned.
The pthread_getunique_np subroutine is unsuccessful if the following is true:
Item | Description |
---|---|
EINVAL | The thread or sequence parameters are not valid. |
ESRCH | The thread thread does not exist. |