mirror of
https://github.com/monero-project/monero.git
synced 2024-11-18 00:37:43 +00:00
rpc: sanity check on number of txes in a block
This commit is contained in:
parent
6795bd0d4e
commit
209ec963b5
1 changed files with 6 additions and 0 deletions
|
@ -258,6 +258,12 @@ namespace cryptonote
|
|||
return false;
|
||||
}
|
||||
}
|
||||
if(b.tx_hashes.size() != bd.second.size())
|
||||
{
|
||||
MERROR("block " << get_block_hash(b) << ": tx_hashes.size() " << b.tx_hashes.size() << ", bd.second.size() " << bd.second.size());
|
||||
res.status = "Failed";
|
||||
return false;
|
||||
}
|
||||
size_t txidx = 0;
|
||||
ntxes += bd.second.size();
|
||||
for (std::list<cryptonote::blobdata>::iterator i = bd.second.begin(); i != bd.second.end(); ++i)
|
||||
|
|
Loading…
Reference in a new issue