Merge branch 'duke' of https://git.hush.is/hush/hush3 into duke

This commit is contained in:
Duke
2024-09-20 13:43:15 -04:00
2 changed files with 23 additions and 32 deletions

View File

@@ -1321,8 +1321,7 @@ void static RandomXMiner()
}
CValidationState state;
{ LOCK(cs_main);
//{ LOCK(cs_main);
if ( !TestBlockValidity(state,B, chainActive.LastTip(), true, false))
{
h = UintToArith256(B.GetHash());
@@ -1333,8 +1332,7 @@ void static RandomXMiner()
fprintf(stderr,"\n");
return(false);
}
}
//}
SetThreadPriority(THREAD_PRIORITY_NORMAL);
LogPrintf("HushRandomXMiner:\n");
LogPrintf("proof-of-work found \n hash: %s \ntarget: %s\n", B.GetHash().GetHex(), HASHTarget.GetHex());
@@ -1693,8 +1691,8 @@ void static BitcoinMiner()
fprintf(stderr," mined %s block %d!\n",SMART_CHAIN_SYMBOL,Mining_height);
}
CValidationState state;
{ LOCK(cs_main);
//{ LOCK(cs_main);
if ( !TestBlockValidity(state,B, chainActive.LastTip(), true, false))
{
h = UintToArith256(B.GetHash());
@@ -1705,7 +1703,7 @@ void static BitcoinMiner()
return(false);
}
}
//}
HUSH_CHOSEN_ONE = 1;
// Found a solution
SetThreadPriority(THREAD_PRIORITY_NORMAL);