#include <pthread.h> int pthread_mutex_consistent_np(pthread_mutex_t *mutex);
Call pthread_mutex_lock() to acquire the inconsistent mutex. The EOWNWERDEAD return value indicates an inconsistent mutex.
Call pthread_mutex_consistent_np() while holding the mutex acquired by a previous call to pthread_mutex_lock().
The critical section protected by the mutex might have been left in an inconsistent state by a failed owner. In this case, make the mutex consistent only if you can make the critical section protected by the mutex consistent.
Calls to pthread_mutex_lock(), pthread_mutex_unlock() , and pthread_mutex_trylock() for a consistent mutex behave in the normal manner.
The behavior of pthread_mutex_consistent_np() for a mutex that is not inconsistent, or is not held, is undefined.