summaryrefslogtreecommitdiff
path: root/src/thread-pool.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'src/thread-pool.cpp')
-rw-r--r--src/thread-pool.cpp1
1 files changed, 1 insertions, 0 deletions
diff --git a/src/thread-pool.cpp b/src/thread-pool.cpp
index f110e42..68353b9 100644
--- a/src/thread-pool.cpp
+++ b/src/thread-pool.cpp
@@ -43,6 +43,7 @@ void ThreadRun(ThreadPool *tp) {
}
assert(j != nullptr);
(*j)();
+ j->~packaged_task<void()>();
pk_delete<std::packaged_task<void()>>(j, tp->bkt);
tp->completedCount = tp->completedCount + 1;
}