pthread_attr_destroy()

Destroy a thread-attribute object

Synopsis:

#include <pthread.h>

int pthread_attr_destroy( pthread_attr_t * attr );

Arguments:

attr
A pointer to the pthread_attr_t structure that you want to destroy.

Library:

libc

Use the -l c option to qcc to link against this library. This library is usually included automatically.

Description:

The pthread_attr_destroy() function destroys the given thread-attribute object.

Note: The QNX implementation of this function doesn't actually free the memory used by the pthread_attr_t structure. To conform to the POSIX standard, don't reuse the attribute object unless you reinitialize it by calling pthread_attr_init().

You can use a thread-attribute object to define the attributes of new threads when you call pthread_create().

Returns:

0 for success, or an error number.

Errors:

EOK
Success.

Classification:

POSIX 1003.1 THR

Safety:  
Cancellation point No
Interrupt handler No
Signal handler Yes
Thread Yes