From 79a179a0f2b655b0e62b8808b39a89bdca017729 Mon Sep 17 00:00:00 2001 From: JoelKatz Date: Thu, 31 May 2012 18:22:18 -0700 Subject: [PATCH] Don't take our initial position until the wobble time is over. --- src/LedgerConsensus.cpp | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/src/LedgerConsensus.cpp b/src/LedgerConsensus.cpp index 4a065bf330..5b3744484a 100644 --- a/src/LedgerConsensus.cpp +++ b/src/LedgerConsensus.cpp @@ -239,7 +239,7 @@ void LedgerConsensus::adjustCount(SHAMap::pointer map, const std::vectorgetLedgerSeq()); @@ -277,6 +277,9 @@ int LedgerConsensus::statePostClose(int secondsSinceClose) { Log(lsINFO) << "Wobble is over, it's consensus time"; mState = lcsESTABLISH; + Ledger::pointer initial = theApp->getMasterLedger().getCurrentLedger(); + takeInitialPosition(initial); + initial->bumpSeq(); } return 1; } @@ -406,8 +409,6 @@ void LedgerConsensus::closeLedger() Log(lsINFO) << "Closing ledger"; Ledger::pointer initial = theApp->getMasterLedger().getCurrentLedger(); statusChange(newcoin::neCLOSING_LEDGER, initial); - takeInitialPosition(initial); - initial->bumpSeq(); statusChange(newcoin::neCLOSING_LEDGER, mPreviousLedger); }