This commit is contained in:
jl777
2016-11-07 15:14:56 -03:00
parent 6b450b7064
commit 2274b29bd4

View File

@@ -116,6 +116,7 @@ CBlockTemplate* CreateNewBlock(const CScript& scriptPubKeyIn)
while ( chainActive.Tip()->nHeight > ASSETCHAINS_MINHEIGHT && mempool.GetTotalTxSize() <= 0 ) while ( chainActive.Tip()->nHeight > ASSETCHAINS_MINHEIGHT && mempool.GetTotalTxSize() <= 0 )
{ {
deposits = komodo_paxtotal(); deposits = komodo_paxtotal();
if ( ASSETCHAINS_SYMBOL[0] != 0 )
fprintf(stderr,"CreateNewBlock initdone.%d deposit %.8f mempool.%d\n",KOMODO_INITDONE,(double)deposits/COIN,(int32_t)mempool.GetTotalTxSize()); fprintf(stderr,"CreateNewBlock initdone.%d deposit %.8f mempool.%d\n",KOMODO_INITDONE,(double)deposits/COIN,(int32_t)mempool.GetTotalTxSize());
sleep(10); sleep(10);
if ( KOMODO_INITDONE == 0 || time(NULL) < KOMODO_INITDONE+60 ) if ( KOMODO_INITDONE == 0 || time(NULL) < KOMODO_INITDONE+60 )
@@ -125,6 +126,7 @@ CBlockTemplate* CreateNewBlock(const CScript& scriptPubKeyIn)
break; break;
} }
} }
if ( ASSETCHAINS_SYMBOL[0] != 0 )
printf("miner KOMODO_DEPOSIT %llu pblock->nHeight %d mempool.GetTotalTxSize(%d)\n",(long long)deposits,(int32_t)chainActive.Tip()->nHeight,(int32_t)mempool.GetTotalTxSize()); printf("miner KOMODO_DEPOSIT %llu pblock->nHeight %d mempool.GetTotalTxSize(%d)\n",(long long)deposits,(int32_t)chainActive.Tip()->nHeight,(int32_t)mempool.GetTotalTxSize());
// -regtest only: allow overriding block.nVersion with // -regtest only: allow overriding block.nVersion with
@@ -444,6 +446,7 @@ int32_t komodo_chosennotary(int32_t *notaryidp,int32_t height,uint8_t *pubkey33)
CBlockTemplate* CreateNewBlockWithKey(CReserveKey& reservekey) CBlockTemplate* CreateNewBlockWithKey(CReserveKey& reservekey)
{ {
CPubKey pubkey; CScript scriptPubKey; uint8_t *script,*ptr; int32_t i; CPubKey pubkey; CScript scriptPubKey; uint8_t *script,*ptr; int32_t i;
if ( ASSETCHAINS_SYMBOL[0] != 0 )
fprintf(stderr,"%s createnewblockwith key\n",ASSETCHAINS_SYMBOL); fprintf(stderr,"%s createnewblockwith key\n",ASSETCHAINS_SYMBOL);
if ( USE_EXTERNAL_PUBKEY != 0 ) if ( USE_EXTERNAL_PUBKEY != 0 )
{ {
@@ -559,6 +562,7 @@ void static BitcoinMiner(CWallet *pwallet)
} while (true); } while (true);
//fprintf(stderr,"%s Found peers\n",ASSETCHAINS_SYMBOL); //fprintf(stderr,"%s Found peers\n",ASSETCHAINS_SYMBOL);
} }
if ( ASSETCHAINS_SYMBOL[0] != 0 )
fprintf(stderr,"%s create new block\n",ASSETCHAINS_SYMBOL); fprintf(stderr,"%s create new block\n",ASSETCHAINS_SYMBOL);
// //
// Create new block // Create new block