1
0
Fork 0
mirror of https://github.com/ton-blockchain/ton synced 2025-03-09 15:40:10 +00:00

updated pow-miner + small bugfix

This commit is contained in:
ton 2020-07-10 13:46:16 +03:00 committed by tolya-yanot
parent b84e3e9735
commit b36118dd27
16 changed files with 344 additions and 25 deletions

View file

@ -1958,6 +1958,7 @@ void ValidatorManagerImpl::add_handle_to_lru(BlockHandle handle) {
auto it = handle_lru_map_.find(handle->id());
if (it != handle_lru_map_.end()) {
CHECK(it->second->handle() == handle);
it->second->remove();
handle_lru_.put(it->second.get());
} else {
auto id = handle->id();
@ -1978,6 +1979,7 @@ void ValidatorManagerImpl::add_handle_to_lru(BlockHandle handle) {
BlockHandle ValidatorManagerImpl::get_handle_from_lru(BlockIdExt id) {
auto it = handle_lru_map_.find(id);
if (it != handle_lru_map_.end()) {
it->second->remove();
handle_lru_.put(it->second.get());
auto handle = it->second->handle();
CHECK(handle->id() == id);