miner: fix race when stopping mining with start mining enabled

This commit is contained in:
moneromooo-monero 2019-03-15 19:08:22 +00:00
parent 4308a2e173
commit def4016171
2 changed files with 10 additions and 6 deletions

View file

@ -125,6 +125,7 @@ namespace cryptonote
uint64_t m_height;
volatile uint32_t m_thread_index;
volatile uint32_t m_threads_total;
std::atomic<uint32_t> m_threads_active;
std::atomic<int32_t> m_pausers_count;
epee::critical_section m_miners_count_lock;