#include <pthread.h> int
pthread_cond_init (pthread_cond_t *cond const pthread_condattr_t *attr);
DESCRIPTION
The
pthread_cond_init ();
function creates a new condition variable, with attributes specified with
Fa attr .
If
Fa attr
is NULL the default attributes are used.
RETURN VALUES
If successful, the
pthread_cond_init ();
function will return zero and put the new condition variable id into
Fa cond ,
otherwise an error number will be returned to indicate the error.
ERRORS
The
pthread_cond_init ();
function will fail if:
Bq Er EINVAL
The value specified by
Fa attr
is invalid.
Bq Er ENOMEM
The process cannot allocate enough memory to create another condition
variable.
Bq Er EAGAIN
The system temporarily lacks the resources to create another condition
variable.