OpenBSD manual page server

Manual Page Search Parameters

PTHREAD_BARRIERATTR_INIT(3) Library Functions Manual PTHREAD_BARRIERATTR_INIT(3)

pthread_barrierattr_init, pthread_barrierattr_destroyinitialize and destroy a barrier attribute object

#include <pthread.h>

int
pthread_barrierattr_init(pthread_barrierattr_t *attr);

int
pthread_barrierattr_destroy(pthread_barrierattr_t *attr);

The () function creates a new barrier attribute object.

The () function frees the resources allocated for attr.

If successful, pthread_barrierattr_init() and pthread_barrierattr_destroy() return zero; otherwise an error number is returned to indicate the error.

pthread_barrierattr_init() will fail if:

[]
The value specified by attr is invalid.
[]
The process cannot allocate enough memory to create another barrier attribute object.

pthread_barrierattr_destroy() will fail if:

[]
The value specified by attr is invalid.

pthread_barrier_init(3), pthread_barrier_wait(3), pthread_barrierattr_getpshared(3)

pthread_barrierattr_init() and pthread_barrierattr_destroy() conform to IEEE Std 1003.1-2008 (“POSIX.1”).

April 6, 2020 OpenBSD-current