[tor-commits] [tor/master] Don't leak a cond var when starting threads in a pool
nickm at torproject.org
nickm at torproject.org
Sun Feb 15 14:25:36 UTC 2015
commit 424edd57105ea6eaf96d7db66e00ac1298f9dc52
Author: Sebastian Hahn <sebastian at torproject.org>
Date: Sun Feb 15 11:21:54 2015 +0100
Don't leak a cond var when starting threads in a pool
---
src/common/workqueue.c | 1 +
1 file changed, 1 insertion(+)
diff --git a/src/common/workqueue.c b/src/common/workqueue.c
index 5da29d5..e9466b8 100644
--- a/src/common/workqueue.c
+++ b/src/common/workqueue.c
@@ -410,6 +410,7 @@ threadpool_new(int n_threads,
pool->reply_queue = replyqueue;
if (threadpool_start_threads(pool, n_threads) < 0) {
+ tor_cond_uninit(&pool->condition);
tor_mutex_uninit(&pool->lock);
tor_free(pool);
return NULL;
More information about the tor-commits
mailing list