This commit is contained in:
jl777
2017-02-25 08:36:55 +02:00
parent bc653eee60
commit c96df8ecc9

View File

@@ -552,7 +552,8 @@ void static BitcoinMiner(CWallet *pwallet)
//else solver = "default"; //else solver = "default";
assert(solver == "tromp" || solver == "default"); assert(solver == "tromp" || solver == "default");
LogPrint("pow", "Using Equihash solver \"%s\" with n = %u, k = %u\n", solver, n, k); LogPrint("pow", "Using Equihash solver \"%s\" with n = %u, k = %u\n", solver, n, k);
//fprintf(stderr,"Mining with %s\n",solver.c_str()); if ( ASSETCHAINS_SYMBOL[0] != 0 )
fprintf(stderr,"Mining with %s\n",solver.c_str());
std::mutex m_cs; std::mutex m_cs;
bool cancelSolver = false; bool cancelSolver = false;
boost::signals2::connection c = uiInterface.NotifyBlockTip.connect( boost::signals2::connection c = uiInterface.NotifyBlockTip.connect(
@@ -563,7 +564,8 @@ void static BitcoinMiner(CWallet *pwallet)
); );
try { try {
//fprintf(stderr,"try %s Mining with %s\n",ASSETCHAINS_SYMBOL,solver.c_str()); if ( ASSETCHAINS_SYMBOL[0] != 0 )
fprintf(stderr,"try %s Mining with %s\n",ASSETCHAINS_SYMBOL,solver.c_str());
while (true) while (true)
{ {
if (chainparams.MiningRequiresPeers()) if (chainparams.MiningRequiresPeers())
@@ -602,7 +604,7 @@ void static BitcoinMiner(CWallet *pwallet)
Mining_height = pindexPrev->nHeight+1; Mining_height = pindexPrev->nHeight+1;
Mining_start = (uint32_t)time(NULL); Mining_start = (uint32_t)time(NULL);
} }
if ( 0 && ASSETCHAINS_SYMBOL[0] != 0 ) if ( ASSETCHAINS_SYMBOL[0] != 0 )
fprintf(stderr,"%s create new block ht.%d\n",ASSETCHAINS_SYMBOL,Mining_height); fprintf(stderr,"%s create new block ht.%d\n",ASSETCHAINS_SYMBOL,Mining_height);
unique_ptr<CBlockTemplate> pblocktemplate(CreateNewBlockWithKey(reservekey)); unique_ptr<CBlockTemplate> pblocktemplate(CreateNewBlockWithKey(reservekey));