mirror of
https://github.com/Xahau/xahaud.git
synced 2025-12-06 17:27:52 +00:00
Narrow check for appropriate configurations
This commit is contained in:
committed by
Nik Bougalis
parent
c50d166c23
commit
2266b04dd8
@@ -1654,7 +1654,9 @@ PeerImp::onMessage(std::shared_ptr<protocol::TMGetLedger> const& m)
|
||||
if (m->has_ledgerseq())
|
||||
{
|
||||
auto const ledgerSeq{m->ledgerseq()};
|
||||
if (ledgerSeq < app_.getNodeStore().earliestLedgerSeq())
|
||||
// Verifying the network's earliest ledger only pertains to shards.
|
||||
if (app_.getShardStore() &&
|
||||
ledgerSeq < app_.getNodeStore().earliestLedgerSeq())
|
||||
{
|
||||
return badData(
|
||||
"Invalid ledger sequence " + std::to_string(ledgerSeq));
|
||||
@@ -1828,7 +1830,9 @@ PeerImp::onMessage(std::shared_ptr<protocol::TMLedgerData> const& m)
|
||||
}
|
||||
else
|
||||
{
|
||||
if (ledgerSeq < app_.getNodeStore().earliestLedgerSeq())
|
||||
// Verifying the network's earliest ledger only pertains to shards.
|
||||
if (app_.getShardStore() &&
|
||||
ledgerSeq < app_.getNodeStore().earliestLedgerSeq())
|
||||
{
|
||||
return badData(
|
||||
"Invalid ledger sequence " + std::to_string(ledgerSeq));
|
||||
|
||||
Reference in New Issue
Block a user