From 8d06822be59b703e0415618913acc1cc9a633b38 Mon Sep 17 00:00:00 2001 From: Leonid Fedorov Date: Mon, 10 Jul 2023 16:44:35 +0000 Subject: [PATCH] atomic stop flag --- utils/threadpool/threadpool.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/utils/threadpool/threadpool.h b/utils/threadpool/threadpool.h index d12d15390..ea9f89da6 100644 --- a/utils/threadpool/threadpool.h +++ b/utils/threadpool/threadpool.h @@ -350,7 +350,7 @@ class ThreadPool boost::condition_variable fNeedThread; // triggered when a thread is needed ThreadPoolGroup fThreads; - bool fStop; + std::atomic fStop = false; long fGeneralErrors; long fFunctorErrors; uint32_t waitingFunctorsSize;