mirror of
https://github.com/SChernykh/p2pool.git
synced 2024-12-22 11:29:23 +00:00
Added missing integrity check
This commit is contained in:
parent
15354e5a88
commit
4837b4c863
1 changed files with 4 additions and 3 deletions
|
@ -197,9 +197,10 @@ void BlockCache::load_all(SideChain& side_chain, P2PServer& server)
|
|||
continue;
|
||||
}
|
||||
|
||||
block.deserialize(data + sizeof(uint32_t), n, side_chain);
|
||||
server.add_cached_block(block);
|
||||
++blocks_loaded;
|
||||
if (block.deserialize(data + sizeof(uint32_t), n, side_chain) == 0) {
|
||||
server.add_cached_block(block);
|
||||
++blocks_loaded;
|
||||
}
|
||||
}
|
||||
|
||||
LOGINFO(1, "loaded " << blocks_loaded << " cached blocks");
|
||||
|
|
Loading…
Reference in a new issue