From b8e82d59b7aba7da65e4244a29b92274aa50d08d Mon Sep 17 00:00:00 2001 From: Rainer Gerhards Date: Fri, 26 Sep 2008 16:10:05 +0200 Subject: fixed potential race condition on HUP and termination --- runtime/wtp.c | 2 ++ 1 file changed, 2 insertions(+) diff --git a/runtime/wtp.c b/runtime/wtp.c index 8b041ea2..54f12b2b 100644 --- a/runtime/wtp.c +++ b/runtime/wtp.c @@ -169,7 +169,9 @@ wtpWakeupAllWrkr(wtp_t *pThis) DEFiRet; ISOBJ_TYPE_assert(pThis, wtp); + d_pthread_mutex_lock(pThis->pmutUsr); pthread_cond_broadcast(pThis->pcondBusy); + d_pthread_mutex_unlock(pThis->pmutUsr); RETiRet; } -- cgit