added --rand-nonce option to try random instead of sequentially increasing nonces
This commit is contained in:
parent
b6bf6d9bc9
commit
6516517235
7 changed files with 31 additions and 8 deletions
|
@ -54,7 +54,11 @@ void SingleWorker::start()
|
|||
}
|
||||
|
||||
m_count++;
|
||||
*m_job.nonce() = ++m_result.nonce;
|
||||
if (m_job.isRandNonce()) {
|
||||
*m_job.nonce() = m_result.nonce += rand();
|
||||
} else {
|
||||
*m_job.nonce() = ++m_result.nonce;
|
||||
}
|
||||
|
||||
if (CryptoNight::hash(m_job, m_result, m_ctx)) {
|
||||
Workers::submit(m_result);
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue