diff options
author | moneromooo-monero <moneromooo-monero@users.noreply.github.com> | 2019-10-31 01:05:58 +0000 |
---|---|---|
committer | moneromooo-monero <moneromooo-monero@users.noreply.github.com> | 2019-10-31 01:06:42 +0000 |
commit | ebc6ce44f407fab07955fc230f4cab59742fd959 (patch) | |
tree | e440ac44d8fb69c6f53d93252814c6b679fc89da /src/rpc | |
parent | Merge pull request #6044 (diff) | |
download | monero-ebc6ce44f407fab07955fc230f4cab59742fd959.tar.xz |
cryptonote: untangle dependency from miner to blockchain
It causes link errors at least on mac
Diffstat (limited to 'src/rpc')
-rw-r--r-- | src/rpc/core_rpc_server.cpp | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/src/rpc/core_rpc_server.cpp b/src/rpc/core_rpc_server.cpp index df264dde6..7c0c6a8c4 100644 --- a/src/rpc/core_rpc_server.cpp +++ b/src/rpc/core_rpc_server.cpp @@ -1833,7 +1833,9 @@ namespace cryptonote return false; } b.nonce = req.starting_nonce; - miner::find_nonce_for_given_block(&(m_core.get_blockchain_storage()), b, template_res.difficulty, template_res.height); + miner::find_nonce_for_given_block([this](const cryptonote::block &b, uint64_t height, unsigned int threads, crypto::hash &hash) { + return cryptonote::get_block_longhash(&(m_core.get_blockchain_storage()), b, hash, height, threads); + }, b, template_res.difficulty, template_res.height); submit_req.front() = string_tools::buff_to_hex_nodelimer(block_to_blob(b)); r = on_submitblock(submit_req, submit_res, error_resp, ctx); |