Request missing history when behind the ledger cap. (#165)

This commit is contained in:
Ravin Perera
2020-11-25 16:11:46 +05:30
committed by GitHub
parent 29425095e0
commit c41b37fd52
8 changed files with 138 additions and 120 deletions

View File

@@ -218,7 +218,7 @@ namespace p2p
// If max number of history requests reached skip the rest.
if (ledger::sync_ctx.collected_history_requests.size() < ledger::HISTORY_REQ_LIST_CAP)
{
const p2p::history_request hr = p2pmsg::create_history_request_from_msg(*content->message_as_History_Request_Message());
const p2p::history_request hr = p2pmsg::create_history_request_from_msg(*content->message_as_History_Request_Message(), container->lcl());
ledger::sync_ctx.collected_history_requests.push_back(std::make_pair(session.uniqueid, std::move(hr)));
}
else