From f07e6d82f69c79f6d77cfbc58076563cf7836551 Mon Sep 17 00:00:00 2001 From: JoelKatz Date: Sun, 21 Apr 2013 16:34:10 -0700 Subject: [PATCH] Fix a bug that can cause us to fail to realize we're in sync. --- src/cpp/ripple/LedgerConsensus.cpp | 3 +++ 1 file changed, 3 insertions(+) diff --git a/src/cpp/ripple/LedgerConsensus.cpp b/src/cpp/ripple/LedgerConsensus.cpp index 518a736e2..4878f15eb 100644 --- a/src/cpp/ripple/LedgerConsensus.cpp +++ b/src/cpp/ripple/LedgerConsensus.cpp @@ -290,7 +290,10 @@ void LedgerConsensus::handleLCL(const uint256& lclHash) { // we need to switch the ledger we're working from Ledger::pointer newLCL = theApp->getLedgerMaster().getLedgerByHash(lclHash); if (newLCL) + { mPreviousLedger = newLCL; + mPrevLedgerHash = newLCL->getHash(); + } else if (!mAcquiringLedger || (mAcquiringLedger->getHash() != mPrevLedgerHash)) { // need to start acquiring the correct consensus LCL cLog(lsWARNING) << "Need consensus ledger " << mPrevLedgerHash;