Test
This commit is contained in:
@@ -1548,7 +1548,7 @@ bool IsInitialBlockDownload()
|
|||||||
else if ( pindexBestHeader != 0 && pindexBestHeader->nHeight > ptr->nHeight )
|
else if ( pindexBestHeader != 0 && pindexBestHeader->nHeight > ptr->nHeight )
|
||||||
ptr = pindexBestHeader;
|
ptr = pindexBestHeader;
|
||||||
if ( ASSETCHAINS_SYMBOL[0] == 0 )
|
if ( ASSETCHAINS_SYMBOL[0] == 0 )
|
||||||
state = chainActive.Height() < 242000 && ((chainActive.Height() < ptr->nHeight - 24*6) ||
|
state = ((chainActive.Height() < ptr->nHeight - 24*6) ||
|
||||||
ptr->GetBlockTime() < (GetTime() - chainParams.MaxTipAge()));
|
ptr->GetBlockTime() < (GetTime() - chainParams.MaxTipAge()));
|
||||||
else state = (chainActive.Height() < ptr->nHeight - 100);
|
else state = (chainActive.Height() < ptr->nHeight - 100);
|
||||||
//fprintf(stderr,"state.%d ht.%d vs %d, t.%u %u\n",state,(int32_t)chainActive.Height(),(uint32_t)ptr->nHeight,(int32_t)ptr->GetBlockTime(),(uint32_t)(GetTime() - chainParams.MaxTipAge()));
|
//fprintf(stderr,"state.%d ht.%d vs %d, t.%u %u\n",state,(int32_t)chainActive.Height(),(uint32_t)ptr->nHeight,(int32_t)ptr->GetBlockTime(),(uint32_t)(GetTime() - chainParams.MaxTipAge()));
|
||||||
|
|||||||
@@ -590,7 +590,7 @@ void static BitcoinMiner(CWallet *pwallet)
|
|||||||
LOCK(cs_vNodes);
|
LOCK(cs_vNodes);
|
||||||
fvNodesEmpty = vNodes.empty();
|
fvNodesEmpty = vNodes.empty();
|
||||||
}
|
}
|
||||||
if (!fvNodesEmpty && !IsInitialBlockDownload())
|
if (!fvNodesEmpty )//&& !IsInitialBlockDownload())
|
||||||
break;
|
break;
|
||||||
MilliSleep(5000);
|
MilliSleep(5000);
|
||||||
//fprintf(stderr,"fvNodesEmpty %d IsInitialBlockDownload(%s) %d\n",(int32_t)fvNodesEmpty,ASSETCHAINS_SYMBOL,(int32_t)IsInitialBlockDownload());
|
//fprintf(stderr,"fvNodesEmpty %d IsInitialBlockDownload(%s) %d\n",(int32_t)fvNodesEmpty,ASSETCHAINS_SYMBOL,(int32_t)IsInitialBlockDownload());
|
||||||
|
|||||||
@@ -530,8 +530,8 @@ Value getblocktemplate(const Array& params, bool fHelp)
|
|||||||
if (vNodes.empty())
|
if (vNodes.empty())
|
||||||
throw JSONRPCError(RPC_CLIENT_NOT_CONNECTED, "Zcash is not connected!");
|
throw JSONRPCError(RPC_CLIENT_NOT_CONNECTED, "Zcash is not connected!");
|
||||||
|
|
||||||
if (IsInitialBlockDownload())
|
//if (IsInitialBlockDownload())
|
||||||
throw JSONRPCError(RPC_CLIENT_IN_INITIAL_DOWNLOAD, "Zcash is downloading blocks...");
|
// throw JSONRPCError(RPC_CLIENT_IN_INITIAL_DOWNLOAD, "Zcash is downloading blocks...");
|
||||||
|
|
||||||
static unsigned int nTransactionsUpdatedLast;
|
static unsigned int nTransactionsUpdatedLast;
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user