VMS Help  —  POSIX Threads, TIS routines, tis_key_delete
    Deletes the specified thread-specific data key.

1  –  C Binding

    #include <tis.h>

    int
    tis_key_delete (
                pthread_key_t   key);

2  –  Arguments

 key

    Thread-specific data key to be deleted.

3  –  Description

    This routine deletes a thread-specific data key key previously
    returned by a call to the tis_key_create() routine. The data
    values associated with key need not be NULL at the time this
    routine is called. The application must free any application
    storage or perform any cleanup actions for data structures
    related to the deleted key or associated data. This cleanup can
    be done before or after this routine is called. If the cleanup
    is done after this routine is called, the application must have a
    private mechanism to access any and all thread-specific values,
    contexts, and so on.

    Attempting to use the thread-specific data key key after calling
    this routine results in unpredictable behavior.

    No destructor functions are invoked by this routine. Any
    destructor functions that may have been associated with key will
    no longer be called upon thread exit.

    This routine can be called from destructor functions.

4  –  Return Values

    If an error condition occurs, this routine returns an integer
    indicating the type of error. Possible return values are as
    follows:

    Return      Description

    0           Successful completion.
    [EINVAL]    The value for key is invalid.

5  –  Associated Routines

       tis_getspecific()
       tis_key_create()
       tis_setspecific()
Close Help