VMS Help
POSIX Threads, PTHREAD routines, pthread_rwlock_destroy

 *Conan The Librarian (sorry for the slow response - running on an old VAX)

    Destroys a read-write lock object.

  1 - C Binding

    #include <pthread.h>

    int
    pthread_rwlock_destroy (
             pthread_rwlock_t   *rwlock);

  2 - Arguments

 rwlock

    Address of the read-write lock object to be destroyed.

  3 - Description

    This routine destroys the specified read-write lock object by
    uninitializing it, and should be called when the object is no
    longer referenced in your program. After this routine is called,
    the Threads Library may reclaim internal storage used by the
    specified read-write lock object. The effect of subsequent use of
    the lock is undefined until the lock is reinitialized by another
    call to pthread_rwlock_init().

    It is illegal to destroy a locked read-write lock.

    The results of this routine are unpredictable if the specified
    read-write lock object does not currently exist or is not
    initialized. This routine destroys the read-write lock object
    specified by the rwlock argument and releases any resources that
    the object used.

    A destroyed read-write lock object can be reinitialized using the
    pthread_rwlock_init() routine. The results of otherwise
    referencing a destroyed read-write lock object are undefined.

  4 - Return Values

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

    Return      Description

    0           Successful completion.
    [EBUSY]     An attempt was made to destroy the object referenced
                by rwlock while it is locked or referenced.

  5 - Associated Routines

       pthread_rwlock_init()
  Close     HLB-list     TLB-list     Help  

[legal] [privacy] [GNU] [policy] [netiquette] [sponsors] [FAQ]
Tweet
Polarhome, production since 1999.
Member of Polarhome portal.