From: simonmar Date: Thu, 26 Feb 2004 16:49:34 +0000 (+0000) Subject: [project @ 2004-02-26 16:49:34 by simonmar] X-Git-Tag: Approx_11550_changesets_converted~45 X-Git-Url: http://git.megacz.com/?a=commitdiff_plain;h=0effbe4b69eb1ec22ff097b533d76b0bdb85322f;p=ghc-hetmet.git [project @ 2004-02-26 16:49:34 by simonmar] waitCondition: use RELEASE_LOCK/ACQUIRE_LOCK because these check the return value for errors. --- diff --git a/ghc/rts/OSThreads.c b/ghc/rts/OSThreads.c index 1f44f81..cac4abe 100644 --- a/ghc/rts/OSThreads.c +++ b/ghc/rts/OSThreads.c @@ -178,10 +178,10 @@ signalCondition ( Condition* pCond ) rtsBool waitCondition ( Condition* pCond, Mutex* pMut ) { - ReleaseMutex(*pMut); + RELEASE_LOCK(*pMut); WaitForSingleObject(*pCond, INFINITE); /* Hmm..use WaitForMultipleObjects() ? */ - WaitForSingleObject(*pMut, INFINITE); + ACQUIRE_LOCK(*pMut, INFINITE); return rtsTrue; }