Fix a bug that would cause the server to exit the "need network ledger" state prematurely.

This commit is contained in:
JoelKatz
2012-12-30 23:48:53 -08:00
parent bafa5cb667
commit 40b87e9157
2 changed files with 3 additions and 2 deletions

View File

@@ -425,7 +425,7 @@ void LedgerConsensus::handleLCL(const uint256& lclHash)
cLog(lsINFO) << "Have the consensus ledger " << mPrevLedgerHash;
mHaveCorrectLCL = true;
mAcquiringLedger.reset();
if (mAcquiringLedger->isComplete())
theApp->getOPs().clearNeedNetworkLedger();
mCloseResolution = ContinuousLedgerTiming::getNextLedgerTimeResolution(
mPreviousLedger->getCloseResolution(), mPreviousLedger->getCloseAgree(),

View File

@@ -770,6 +770,7 @@ bool NetworkOPs::checkLastClosedLedger(const std::vector<Peer::pointer>& peerLis
}
return true;
}
clearNeedNetworkLedger();
consensus = mAcquiringLedger->getLedger();
}