pthread_cond_broadcast()

broadcast a condition 

Function


SYNOPSIS

#include <pthread.h>

int pthread_cond_broadcast(pthread_cond_t *cond);


DESCRIPTION

The pthread_cond_broadcast() function unblocks all threads blocked on the specified condition variable. The function has no effect if no threads are blocked on the condition variable. pthread_cond_broadcast() may be called by a thread whether or not it owns the mutex which threads calling pthread_cond_wait() or pthread_cond_timedwait() have associated with the condition variable during their waits. However, if predictable scheduling behavior is required, then that mutex should be locked by the thread calling pthread_cond_broadcast().


PARAMETERS

cond 

Is the condition variable to broadcast.


RETURN VALUES

On success, pthread_cond_broadcast() returns 0. On error, one of the following values is returned:

EINVAL 

cond does not refer to an initialized condition variable.

EFAULT 

cond is an invalid pointer.


CONFORMANCE

POSIX P1003.1 (1996)


MULTITHREAD SAFETY LEVEL

MT-safe.


PORTING ISSUES

None.


AVAILABILITY

PTC MKS Toolkit for Professional Developers
PTC MKS Toolkit for Professional Developers 64-Bit Edition
PTC MKS Toolkit for Enterprise Developers
PTC MKS Toolkit for Enterprise Developers 64-Bit Edition


SEE ALSO

Functions:
pthread_cond_init(), pthread_cond_signal(), pthread_cond_timedwait(), pthread_cond_wait()


PTC MKS Toolkit 10.4 Documentation Build 39.