Date: Tue, 24 Mar 2026 20:37:13 -0400
From: Greg Troxel <gdt%lexort.com@localhost>
Message-ID: <rmi4im4agna.fsf%s1.lexort.com@localhost>
| J�rg Sonnenberger <joerg%bec.de@localhost> writes:
| > Neither signal nor broadcast unlocks the mutex. Only cv_wait may
| > release the mutex before blocking.
|
| Makes sense but I can't find that in the POSIX text.
That would be:
The pthread_cond_broadcast() or pthread_cond_signal() functions
may be called by a thread whether or not it currently owns the mutex
If those functions don't know whether or not the caller owns the mutex,
clearly they can't go manipulating the thing, if the current thread doesn't
own it, some other might have it locked, and not appreciate it suddenly
becoming unlocked, for no apparent reason to it.