From c1bc6acd26045f5ec3382832a841733c3262c9e5 Mon Sep 17 00:00:00 2001 From: XMRig Date: Tue, 3 Apr 2018 03:01:04 +0700 Subject: [PATCH] Fix DoubleWorker. --- src/workers/DoubleWorker.cpp | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/workers/DoubleWorker.cpp b/src/workers/DoubleWorker.cpp index 3dba4a9fb..7bde7df94 100644 --- a/src/workers/DoubleWorker.cpp +++ b/src/workers/DoubleWorker.cpp @@ -26,7 +26,7 @@ #include -#include "crypto/CryptoNight.h" +#include "workers/CpuThread.h" #include "workers/DoubleWorker.h" #include "workers/Workers.h" @@ -86,7 +86,7 @@ void DoubleWorker::start() *Job::nonce(m_state->blob) = ++m_state->nonce1; *Job::nonce(m_state->blob + m_state->job.size()) = ++m_state->nonce2; - CryptoNight::hash(m_state->blob, m_state->job.size(), m_hash, m_ctx, m_state->job.variant()); + m_thread->fn(m_state->job.variant())(m_state->blob, m_state->job.size(), m_hash, m_ctx); if (*reinterpret_cast(m_hash + 24) < m_state->job.target()) { Workers::submit(JobResult(m_state->job.poolId(), m_state->job.id(), m_state->nonce1, m_hash, m_state->job.diff()));