pthread_rwlockattr_setkind_np(3) Library Functions Manual pthread_rwlockattr_setkind_np, pthread_rwlockattr_getkind_np - / - - - POSIX threads library (libpthread, -lpthread) #include int pthread_rwlockattr_setkind_np(pthread_rwlockattr_t *attr, int pref); int pthread_rwlockattr_getkind_np( const pthread_rwlockattr_t *restrict attr, int *restrict pref); glibc (. feature_test_macros(7)): pthread_rwlockattr_setkind_np(), pthread_rwlockattr_getkind_np(): _XOPEN_SOURCE >= 500 || _POSIX_C_SOURCE >= 200809L pthread_rwlockattr_setkind_np() << >> - -, attr, pref. pref : PTHREAD_RWLOCK_PREFER_READER_NP . ; . Single Unix Specification, , , . PTHREAD_RWLOCK_PREFER_READER_NP , , . . PTHREAD_RWLOCK_PREFER_WRITER_NP This is intended as the write lock analog of PTHREAD_RWLOCK_PREFER_READER_NP. This is ignored by glibc because the POSIX requirement to support recursive read locks would cause this option to create trivial deadlocks; instead use PTHREAD_RWLOCK_PREFER_WRITER_NONRECURSIVE_NP which ensures the application developer will not take recursive read locks thus avoiding deadlocks. PTHREAD_RWLOCK_PREFER_WRITER_NONRECURSIVE_NP . pthread_rwlockattr_getkind_np() << >> - -, attr, pref. 0. pthread_rwlockattr_getkind_np() . pthread_rwlockattr_setkind_np() . EINVAL pref. GNU, <<_np>> (nonportable) . glibc 2.1. pthreads(7) () Alexey, Azamat Hackimov , kogamatranslator49 , Darima Kogan , Max Is , Yuri Kozlov ; GNU (GNU General Public License - GPL, 3 ) , - . - , , () () () <>. Linux 6.9.1 2 2024 . pthread_rwlockattr_setkind_np(3)