Sync changes with proxy.

This commit is contained in:
XMRig 2019-06-25 10:35:10 +07:00
parent f7f2c09e89
commit b0a1481909
5 changed files with 30 additions and 36 deletions

View file

@ -42,8 +42,8 @@ xmrig::Job::Job() :
m_diff(0),
m_height(0),
m_target(0),
m_seedHash(),
m_blob()
m_blob(),
m_seedHash()
{
}
@ -59,8 +59,8 @@ xmrig::Job::Job(int poolId, bool nicehash, const Algorithm &algorithm, const Str
m_diff(0),
m_height(0),
m_target(0),
m_seedHash(),
m_blob()
m_blob(),
m_seedHash()
{
}
@ -113,6 +113,20 @@ bool xmrig::Job::setBlob(const char *blob)
}
bool xmrig::Job::setSeedHash(const char *hash)
{
if (!hash || (strlen(hash) != sizeof(m_seedHash) * 2)) {
return false;
}
# ifdef XMRIG_PROXY_PROJECT
m_rawSeedHash = hash;
# endif
return Buffer::fromHex(hash, sizeof(m_seedHash) * 2, m_seedHash);
}
bool xmrig::Job::setTarget(const char *target)
{
if (!target) {
@ -177,15 +191,6 @@ void xmrig::Job::setDiff(uint64_t diff)
}
bool xmrig::Job::setSeedHash(const char *hash)
{
if (!hash || (strlen(hash) != sizeof(m_seedHash) * 2))
return false;
return Buffer::fromHex(hash, sizeof(m_seedHash) * 2, m_seedHash);
}
xmrig::Variant xmrig::Job::variant() const
{
switch (m_algorithm.algo()) {