Merge pull request #474 from UdjinM6/v0.12.0.x_ref_IsBlockchainSynced

V0.12.0.x use fBlockchainSynced right on IsBlockchainSynced start
This commit is contained in:
evan82 2015-08-03 16:49:25 -07:00
commit 76858b0341

View File

@ -41,6 +41,9 @@ bool CMasternodeSync::IsSynced()
bool CMasternodeSync::IsBlockchainSynced()
{
static bool fBlockchainSynced = false;
if(fBlockchainSynced) return true;
if (fImporting || fReindex) return false;
TRY_LOCK(cs_main, lockMain);
@ -49,8 +52,6 @@ bool CMasternodeSync::IsBlockchainSynced()
CBlockIndex* pindex = chainActive.Tip();
if(pindex == NULL) return false;
static bool fBlockchainSynced = false;
if(fBlockchainSynced) return true;
if(pindex->nTime + 600 < GetTime())
return false;