int pthread_rwlock_trywrlock(pthread_rwlock_t *rwlock);
int pthread_rwlock_wrlock(pthread_rwlock_t *rwlock);
To avoid writer starvation, writers are favored over readers. Readers block while writers are waiting and writers have a greater probability of waking up once blocked.
When a thread waiting to acquire a write lock receives a signal, that thread, upon return from the signal handler, resumes waiting as though no interruption occurred.
On success, the
A write lock was unable to be acquired because rwlock was already locked for reading or writing.
The current thread already owns the read-write lock for writing.
The rwlock argument does not point to an initialized read-write lock object.
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
pthread_rwlock_destroy(), pthread_rwlock_rdlock(), pthread_rwlock_timedrdlock(), pthread_rwlock_timedwrlock(), pthread_rwlock_tryrdlock(), pthread_rwlock_unlock()
PTC MKS Toolkit 10.3 Documentation Build 39.