From 2d48812b47fa6c0f28066a552ec406bc5ca3c3ee Mon Sep 17 00:00:00 2001 From: davidxu Date: Sun, 12 Aug 2012 00:56:56 +0000 Subject: Do defered mutex wakeup once. --- lib/libthr/thread/thr_cond.c | 1 + 1 file changed, 1 insertion(+) (limited to 'lib/libthr') diff --git a/lib/libthr/thread/thr_cond.c b/lib/libthr/thread/thr_cond.c index 541e40a..6af15db 100644 --- a/lib/libthr/thread/thr_cond.c +++ b/lib/libthr/thread/thr_cond.c @@ -239,6 +239,7 @@ cond_wait_user(struct pthread_cond *cvp, struct pthread_mutex *mp, _thr_clear_wake(curthread); _sleepq_unlock(cvp); if (defered) { + defered = 0; if ((mp->m_lock.m_owner & UMUTEX_CONTESTED) == 0) (void)_umtx_op_err(&mp->m_lock, UMTX_OP_MUTEX_WAKE2, mp->m_lock.m_flags, 0, 0); -- cgit v1.1