P2PServer: fixed some excess block requests

pull/271/head
SChernykh 2023-07-07 14:52:47 +02:00
parent df43e2c126
commit d72f0ce40c
1 changed files with 4 additions and 0 deletions

View File

@ -2506,6 +2506,10 @@ void P2PServer::P2PClient::post_handle_incoming_block(const uint32_t reset_count
}
}
if (!server->m_missingBlockRequests.insert({ m_peerId, *id.u64() }).second) {
continue;
}
const bool result = server->send(this,
[this, &id](uint8_t* buf, size_t buf_size) -> size_t
{