29 lines
943 B
Diff
29 lines
943 B
Diff
|
From d91a6cf6e369a79587c5665fce9635e5634ca201 Mon Sep 17 00:00:00 2001
|
||
|
From: Rich Felker <dalias@aerifal.cx>
|
||
|
Date: Fri, 30 Oct 2020 16:50:08 -0400
|
||
|
Subject: fix erroneous pthread_cond_wait mutex waiter count logic due to typo
|
||
|
|
||
|
introduced in commit 27b2fc9d6db956359727a66c262f1e69995660aa.
|
||
|
---
|
||
|
src/thread/pthread_cond_timedwait.c | 2 +-
|
||
|
1 file changed, 1 insertion(+), 1 deletion(-)
|
||
|
|
||
|
(limited to 'src/thread/pthread_cond_timedwait.c')
|
||
|
|
||
|
diff --git a/src/thread/pthread_cond_timedwait.c b/src/thread/pthread_cond_timedwait.c
|
||
|
index a0cd4904..6b761455 100644
|
||
|
--- a/src/thread/pthread_cond_timedwait.c
|
||
|
+++ b/src/thread/pthread_cond_timedwait.c
|
||
|
@@ -155,7 +155,7 @@ relock:
|
||
|
int val = m->_m_lock;
|
||
|
if (val>0) a_cas(&m->_m_lock, val, val|0x80000000);
|
||
|
unlock_requeue(&node.prev->barrier, &m->_m_lock, m->_m_type & (8|128));
|
||
|
- } else if (!!(m->_m_type & 8)) {
|
||
|
+ } else if (!(m->_m_type & 8)) {
|
||
|
a_dec(&m->_m_waiters);
|
||
|
}
|
||
|
|
||
|
--
|
||
|
cgit v1.2.1
|
||
|
|