mirror of
https://github.com/xmrig/xmrig.git
synced 2025-12-10 09:02:45 -05:00
Fixed nicehash nonce overflow for CPU backend.
This commit is contained in:
@@ -6,8 +6,8 @@
|
||||
* Copyright 2016 Jay D Dee <jayddee246@gmail.com>
|
||||
* Copyright 2017-2018 XMR-Stak <https://github.com/fireice-uk>, <https://github.com/psychocrypt>
|
||||
* Copyright 2018 Lee Clagett <https://github.com/vtnerd>
|
||||
* Copyright 2018-2019 SChernykh <https://github.com/SChernykh>
|
||||
* Copyright 2016-2019 XMRig <https://github.com/xmrig>, <support@xmrig.com>
|
||||
* Copyright 2018-2020 SChernykh <https://github.com/SChernykh>
|
||||
* Copyright 2016-2020 XMRig <https://github.com/xmrig>, <support@xmrig.com>
|
||||
*
|
||||
* This program is free software: you can redistribute it and/or modify
|
||||
* it under the terms of the GNU General Public License as published by
|
||||
@@ -55,6 +55,17 @@ public:
|
||||
memcpy(m_result, result, sizeof(m_result));
|
||||
}
|
||||
|
||||
inline JobResult(const Job &job) :
|
||||
algorithm(job.algorithm()),
|
||||
clientId(job.clientId()),
|
||||
jobId(job.id()),
|
||||
backend(job.backend()),
|
||||
nonce(0),
|
||||
diff(0),
|
||||
index(job.index())
|
||||
{
|
||||
}
|
||||
|
||||
inline const uint8_t *result() const { return m_result; }
|
||||
inline uint64_t actualDiff() const { return Job::toDiff(reinterpret_cast<const uint64_t*>(m_result)[3]); }
|
||||
inline uint8_t *result() { return m_result; }
|
||||
|
||||
Reference in New Issue
Block a user