Return Values
pthread_mutex_init() returns zero after completing successfully. Any other returned value indicates that an error occurred. When any of the following conditions occur, the function fails and returns the corresponding value.
-
EBUSY
-
The mutex cannot be reinitialized or modified because it still exists.
-
EINVAL
-
The attribute value is invalid. The mutex has not been modified.
-
EFAULT
-
The address for the mutex pointed at by mp is invalid.