mirror of
https://github.com/xmrig/xmrig.git
synced 2025-12-07 07:55:04 -05:00
Miner: fix state machine
Remove unexpected resume due to disconnect during dataset init
This commit is contained in:
@@ -134,8 +134,6 @@ public:
|
||||
Nonce::pause(true);
|
||||
}
|
||||
|
||||
active = true;
|
||||
|
||||
if (reset) {
|
||||
Nonce::reset(job.index());
|
||||
}
|
||||
@@ -146,7 +144,7 @@ public:
|
||||
|
||||
Nonce::touch();
|
||||
|
||||
if (enabled) {
|
||||
if (active && enabled) {
|
||||
Nonce::pause(false);
|
||||
}
|
||||
|
||||
@@ -536,6 +534,8 @@ void xmrig::Miner::setJob(const Job &job, bool donate)
|
||||
|
||||
mutex.unlock();
|
||||
|
||||
d_ptr->active = true;
|
||||
|
||||
if (ready) {
|
||||
d_ptr->handleJobChange();
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user