Skip to content

gthread: Fix g_rw_lock_reader_lock() documentation

Philip Withnall requested to merge pwithnall/glib:590-rwlock-docs into master

The documentation erroneously said that a thread calling g_rw_lock_reader_lock() would always block if another thread was waiting for the write lock. That’s not true: if no thread holds the lock, it is implementation defined which of a waiting reader and writer gets the lock.

See http://pubs.opengroup.org/onlinepubs/009695399/functions/pthread_rwlock_rdlock.html.

Signed-off-by: Philip Withnall withnall@endlessm.com

Fixes: #590 (closed)

Merge request reports