Multithreaded Programming Guide

mutex_init Return Values

mutex_init() returns 0 if successful. When any of the following conditions is detected, mutex_init() fails and returns the corresponding value.


EFAULT

Description:

mp points to an illegal address.


EINVAL

Description:

The value specified by mp is invalid.


ENOMEM

Description:

System has insufficient memory to initialize the mutex.


EAGAIN

Description:

System has insufficient resources to initialize the mutex.


EBUSY

Description:

System detected an attempt to reinitialize an active mutex.