mirror of
git://git.musl-libc.org/musl
synced 2025-01-30 10:32:04 +00:00
fix breakage in pthread_cond_wait due to typo
due to accidental use of = instead of ==, the error code was always set to zero in the signaled wake case for non-shared cv waits. suppressing ETIMEDOUT (the only possible wait error) is harmless and actually permitted in this case, but suppressing mutex errors could give the caller false information about the state of the mutex. commit8741ffe625
introduced this regression and commitd9da1fb8c5
preserved it when reorganizing the code.
This commit is contained in:
parent
34b423d207
commit
e487c203db
@ -163,7 +163,7 @@ relock:
|
||||
a_dec(&m->_m_waiters);
|
||||
|
||||
/* Since a signal was consumed, cancellation is not permitted. */
|
||||
if (e = ECANCELED) e = 0;
|
||||
if (e == ECANCELED) e = 0;
|
||||
|
||||
done:
|
||||
__pthread_setcancelstate(cs, 0);
|
||||
|
Loading…
Reference in New Issue
Block a user