diff --git a/components/percona_telemetry/worker.cc b/components/percona_telemetry/worker.cc index f0cd387a258b..4572d9ee8518 100644 --- a/components/percona_telemetry/worker.cc +++ b/components/percona_telemetry/worker.cc @@ -25,8 +25,7 @@ Worker::Worker(Config &config, Storage &storage, DataProvider &data_provider, storage_(storage), data_provider_(data_provider), logger_(logger), - stop_worker_thd_(false), - caller_active_(ATOMIC_FLAG_INIT) {} + stop_worker_thd_(false) {} bool Worker::start() { std::thread thd(&Worker::worker_thd_fn, this); diff --git a/components/percona_telemetry/worker.h b/components/percona_telemetry/worker.h index d4f2184e472b..301414a8e1e3 100644 --- a/components/percona_telemetry/worker.h +++ b/components/percona_telemetry/worker.h @@ -44,7 +44,7 @@ class Worker { DataProvider &data_provider_; Logger &logger_; std::atomic_bool stop_worker_thd_; - std::atomic_flag caller_active_; + std::atomic_flag caller_active_ = ATOMIC_FLAG_INIT; std::condition_variable cv_; std::thread thd_;