test_dash continued

Signed-off-by: Pasta <pasta@dashboost.org>
This commit is contained in:
Pasta 2019-12-27 17:45:49 -06:00
parent efea72890c
commit be98dc3894
No known key found for this signature in database
GPG Key ID: 52527BEDABE87984

View File

@ -204,7 +204,10 @@ CBlock TestChainSetup::CreateBlock(const std::vector<CMutableTransaction>& txns,
// IncrementExtraNonce creates a valid coinbase and merkleRoot
unsigned int extraNonce = 0;
IncrementExtraNonce(&block, chainActive.Tip(), extraNonce);
{
LOCK(cs_main);
IncrementExtraNonce(&block, chainActive.Tip(), extraNonce);
}
while (!CheckProofOfWork(block.GetHash(), block.nBits, chainparams.GetConsensus())) ++block.nNonce;