possible race fix in Worker

This commit is contained in:
pusheaxpopebx 2021-09-23 01:14:20 +03:00
parent f7aa5e781b
commit 12690c66d6

View file

@ -20,6 +20,9 @@
#define XMRIG_WORKER_H
#include <atomic>
#include "backend/common/interfaces/IWorker.h"
@ -36,7 +39,7 @@ protected:
inline size_t id() const override { return m_id; }
inline uint32_t node() const { return m_node; }
uint64_t m_count = 0;
std::atomic<uint64_t> m_count = {0};
private:
const int64_t m_affinity;