*nix Documentation Project
·  Home
 +   man pages
·  Linux HOWTOs
·  FreeBSD Tips
·  *niX Forums

  man pages->OpenBSD man pages -> pthread_attr_init (3)              
Title
Content
Arch
Section
 

PTHREAD_ATTR_INIT(3)

Contents


NAME    [Toc]    [Back]

     pthread_attr_init, pthread_attr_destroy - initialise and destroy threads
     attribute object

SYNOPSIS    [Toc]    [Back]

     #include <pthread.h>

     int
     pthread_attr_init(pthread_attr_t *attr);

     int
     pthread_attr_destroy(pthread_attr_t *attr);

DESCRIPTION    [Toc]    [Back]

     The  function  pthread_attr_init()  initialises a thread attributes object
     attr with the default value for all of  the  individual  attributes used by
     a given implementation.

     The resulting attribute object (possibly modified by setting
individual
     attribute values), when used by  pthread_create(3),  defines
the attributes
     of  the  thread  created.  A single attributes object can be
used in multiple
 simultaneous calls to pthread_create(3).

     The pthread_attr_destroy() function is  used  to  destroy  a
thread attributes
     object.    An    implementation    may    cause
pthread_attr_destroy() to
     set attr to an implementation-dependent invalid value.   The
behaviour of
     using  the  attribute  after  it has been destroyed is undefined.

RETURN VALUES    [Toc]    [Back]

     Upon successful completion, pthread_attr_init() and
     pthread_attr_destroy() return a value of 0.   Otherwise,  an
error number
     is returned to indicate the error.

ERRORS    [Toc]    [Back]

     The pthread_attr_init() function will fail if:

     [ENOMEM]       Insufficient  memory exists to initialise the
thread attributes
 object.

     These functions will not return an error code of [EINTR].

SEE ALSO    [Toc]    [Back]

      
      
     pthread_attr_setdetachstate(3),     pthread_attr_setstackaddr(3),
     pthread_attr_setstacksize(3), pthread_create(3), pthreads(3)

STANDARDS    [Toc]    [Back]

     pthread_create()  conforms  to  ISO/IEC   9945-1   ANSI/IEEE
(``POSIX'') Std
     1003.1 Second Edition 1996-07-12.

OpenBSD      3.6                          January     6,     2000
[ Back ]
 Similar pages
Name OS Title
pthread_mutexattr_init IRIX initialize/destroy a mutex attribute object
pthread_condattr_init IRIX initialize/destroy a condition variable attribute object
gludeletetess IRIX destroy a tessellation object
gludeletequadric IRIX destroy a quadrics object
gludeletenurbsrenderer IRIX destroy a NURBS object
gluDeleteNurbsRenderer Tru64 destroy a NURBS object
gluDeleteQuadric Tru64 destroy a quadrics object
gluDeleteTess Tru64 destroy a tessellation object
tt_pattern_destroy HP-UX destroy a pattern object
pthread_attr_setname_np Tru64 Change the object name attribute in a thread attributes object
Copyright © 2004-2005 DeniX Solutions SRL
newsletter delivery service