mirror of
https://github.com/monero-project/monero.git
synced 2025-08-16 22:10:33 -04:00
core_rpc_server: return ID of submitted block
This commit is contained in:
parent
1ce32d8536
commit
842478c5a9
3 changed files with 17 additions and 2 deletions
|
@ -2115,7 +2115,8 @@ namespace cryptonote
|
|||
// Fixing of high orphan issue for most pools
|
||||
// Thanks Boolberry!
|
||||
block b;
|
||||
if(!parse_and_validate_block_from_blob(blockblob, b))
|
||||
crypto::hash blk_id;
|
||||
if(!parse_and_validate_block_from_blob(blockblob, b, blk_id))
|
||||
{
|
||||
error_resp.code = CORE_RPC_ERROR_CODE_WRONG_BLOCKBLOB;
|
||||
error_resp.message = "Wrong block blob";
|
||||
|
@ -2138,6 +2139,7 @@ namespace cryptonote
|
|||
error_resp.message = "Block not accepted";
|
||||
return false;
|
||||
}
|
||||
res.block_id = epee::string_tools::pod_to_hex(blk_id);
|
||||
res.status = CORE_RPC_STATUS_OK;
|
||||
return true;
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue