mirror of
https://git.wownero.com/wownero/wownero.git
synced 2024-08-15 01:03:23 +00:00
Merge pull request #777
8757e46
add blockhashing blob to getblocktemplate (Howard Chu)
This commit is contained in:
commit
ab43e80331
2 changed files with 4 additions and 0 deletions
|
@ -643,8 +643,10 @@ namespace cryptonote
|
||||||
LOG_ERROR("Failed to calculate offset for ");
|
LOG_ERROR("Failed to calculate offset for ");
|
||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
|
blobdata hashing_blob = get_block_hashing_blob(b);
|
||||||
res.prev_hash = string_tools::pod_to_hex(b.prev_id);
|
res.prev_hash = string_tools::pod_to_hex(b.prev_id);
|
||||||
res.blocktemplate_blob = string_tools::buff_to_hex_nodelimer(block_blob);
|
res.blocktemplate_blob = string_tools::buff_to_hex_nodelimer(block_blob);
|
||||||
|
res.blockhashing_blob = string_tools::buff_to_hex_nodelimer(hashing_blob);
|
||||||
res.status = CORE_RPC_STATUS_OK;
|
res.status = CORE_RPC_STATUS_OK;
|
||||||
return true;
|
return true;
|
||||||
}
|
}
|
||||||
|
|
|
@ -445,6 +445,7 @@ namespace cryptonote
|
||||||
uint64_t reserved_offset;
|
uint64_t reserved_offset;
|
||||||
std::string prev_hash;
|
std::string prev_hash;
|
||||||
blobdata blocktemplate_blob;
|
blobdata blocktemplate_blob;
|
||||||
|
blobdata blockhashing_blob;
|
||||||
std::string status;
|
std::string status;
|
||||||
|
|
||||||
BEGIN_KV_SERIALIZE_MAP()
|
BEGIN_KV_SERIALIZE_MAP()
|
||||||
|
@ -453,6 +454,7 @@ namespace cryptonote
|
||||||
KV_SERIALIZE(reserved_offset)
|
KV_SERIALIZE(reserved_offset)
|
||||||
KV_SERIALIZE(prev_hash)
|
KV_SERIALIZE(prev_hash)
|
||||||
KV_SERIALIZE(blocktemplate_blob)
|
KV_SERIALIZE(blocktemplate_blob)
|
||||||
|
KV_SERIALIZE(blockhashing_blob)
|
||||||
KV_SERIALIZE(status)
|
KV_SERIALIZE(status)
|
||||||
END_KV_SERIALIZE_MAP()
|
END_KV_SERIALIZE_MAP()
|
||||||
};
|
};
|
||||||
|
|
Loading…
Reference in a new issue