From: Howard Chu Date: Thu, 18 Oct 2007 06:52:54 +0000 (+0000) Subject: In pool_resume don't touch the condvar if the pool is tearing down. X-Git-Tag: OPENLDAP_REL_ENG_2_4_9~20^2~501 X-Git-Url: https://git.sur5r.net/?a=commitdiff_plain;h=6775e25ba3ec12ba490f613b718f9d4876900514;p=openldap In pool_resume don't touch the condvar if the pool is tearing down. --- diff --git a/libraries/libldap_r/tpool.c b/libraries/libldap_r/tpool.c index 6884f32fc3..06124de96c 100644 --- a/libraries/libldap_r/tpool.c +++ b/libraries/libldap_r/tpool.c @@ -702,7 +702,8 @@ ldap_pvt_thread_pool_resume ( ldap_pvt_thread_mutex_lock(&pool->ltp_mutex); pool->ltp_pause = 0; - ldap_pvt_thread_cond_broadcast(&pool->ltp_cond); + if (pool->ltp_state == LDAP_INT_THREAD_POOL_RUNNING) + ldap_pvt_thread_cond_broadcast(&pool->ltp_cond); ldap_pvt_thread_mutex_unlock(&pool->ltp_mutex); return(0); }