Museum

Home

Lab Overview

Retrotechnology Articles

⇒ Online Manual

Media Vault

Software Library

Restoration Projects

Artifacts Sought

Related Articles

pthread_keycreate(3P)

pthread_setspecific(3P)

PTHREAD_GETSPECIFIC(3P)              BSD               PTHREAD_GETSPECIFIC(3P)



NAME
     pthread_getspecific - Returns the value bound to a key

SYNOPSIS
     #include <pthread.h>

     int pthread_getspecific (key, value)
     pthread_key_t key;
     void **value;

DESCRIPTION
     The pthread_getspecific function stores the value that is bound to the
     specified key for the calling thread in the value argument.  If no data
     has been bound, then a value of null will be stored.

     The arguments specify the following addresses:

     key  Specifies the address of the key that the value argument is bound
          to.

     value
          Specifies the address in which the thread-specific data is stored.

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 value bound to the key argument is stored
     at the value argument, and a value of 0 (zero) is returned.  Otherwise,
     -1 is returned and errno is set to indicate the error.

ERRORS
     If the pthread_getspecific function fails, errno may be set to the
     following value:

     [EINVAL]  The value specified by the key argument is invalid.

SEE ALSO
     pthread_keycreate(3P), pthread_setspecific(3P)

Typewritten Software • bear@typewritten.org • Edmonds, WA 98026