mirror of
https://git.openldap.org/openldap/openldap.git
synced 2025-12-24 00:29:35 -05:00
More for threadqueues
Catch threads that are finishing while pool was pausing
This commit is contained in:
parent
79157d314f
commit
c034282b14
1 changed files with 4 additions and 1 deletions
|
|
@ -971,7 +971,10 @@ ldap_int_thread_pool_wrapper (
|
|||
thread_keys[keyslot].ctx = DELETED_THREAD_CTX;
|
||||
ldap_pvt_thread_mutex_unlock(&ldap_pvt_thread_pool_mutex);
|
||||
|
||||
pq->ltp_open_count--;
|
||||
if (pq->ltp_open_count < 0)
|
||||
pq->ltp_open_count++;
|
||||
else
|
||||
pq->ltp_open_count--;
|
||||
if (pq->ltp_open_count == 0) {
|
||||
if (pool->ltp_finishing)
|
||||
/* let pool_destroy know we're all done */
|
||||
|
|
|
|||
Loading…
Reference in a new issue