[Return to Bookshelf] [Contents] [Previous Section] [Next Section] [Index] [Help]


2.2.3 Thread Attributes

A thread attributes object allows you to specify values for thread attributes other than the defaults when you create a thread with the pthread_create routine. To use a thread attributes object, perform the following steps:

  1. Create a thread attributes object by calling the pthread_ attr_init routine.

  2. Call the routines discussed in the following sections to set the individual attributes of the thread attributes object.

  3. Create a new thread by calling the pthread_create routine and specifying the handle of the thread attributes object.

You have control over the following attributes of a new thread: