diff --git a/src/miner.cpp b/src/miner.cpp index fa8738939..e90493f23 100644 --- a/src/miner.cpp +++ b/src/miner.cpp @@ -571,10 +571,13 @@ void static BitcoinMiner(CWallet *pwallet) // // Create new block // - Mining_start = (uint32_t)time(NULL); unsigned int nTransactionsUpdatedLast = mempool.GetTransactionsUpdated(); CBlockIndex* pindexPrev = chainActive.Tip(); - Mining_height = pindexPrev->nHeight+1; + if ( Mining_height != pindexPrev->nHeight+1 ) + { + Mining_height = pindexPrev->nHeight+1; + Mining_start = (uint32_t)time(NULL); + } if ( ASSETCHAINS_SYMBOL[0] != 0 ) fprintf(stderr,"%s create new block ht.%d\n",ASSETCHAINS_SYMBOL,Mining_height); @@ -596,7 +599,6 @@ void static BitcoinMiner(CWallet *pwallet) if ( ASSETCHAINS_SYMBOL[0] == 0 && komodo_is_special(pindexPrev->nHeight+1,NOTARY_PUBKEY33) > 0 ) { hashTarget = arith_uint256().SetCompact(KOMODO_MINDIFF_NBITS); - Mining_start = (uint32_t)time(NULL); //fprintf(stderr,"I am the chosen one for %s ht.%d\n",ASSETCHAINS_SYMBOL,pindexPrev->nHeight+1); } else Mining_start = 0; while (true) diff --git a/src/pow.cpp b/src/pow.cpp index 7cf20bd83..b7fdb0314 100644 --- a/src/pow.cpp +++ b/src/pow.cpp @@ -131,7 +131,7 @@ bool CheckProofOfWork(int32_t height,uint8_t *pubkey33,uint256 hash, unsigned in { if ( notaryid >= 0 ) { - if ( height < 70000 || komodo_is_special(height,pubkey33) > 0 ) + if ( height < 70000 || special != 0 || komodo_is_special(height,pubkey33) > 0 ) { bnTarget.SetCompact(KOMODO_MINDIFF_NBITS,&fNegative,&fOverflow); flag = 1;