Remove internal miner
This commit is contained in:
12
src/init.cpp
12
src/init.cpp
@@ -187,8 +187,10 @@ void Shutdown()
|
||||
StopREST();
|
||||
StopRPC();
|
||||
StopHTTPServer();
|
||||
|
||||
GenerateBitcoins(false, 0, Params());
|
||||
#ifdef ENABLE_WALLET
|
||||
if (pwalletMain)
|
||||
pwalletMain->Flush(false);
|
||||
#endif
|
||||
StopNode();
|
||||
StopTorControl();
|
||||
UnregisterNodeSignals(GetNodeSignals());
|
||||
@@ -410,8 +412,6 @@ std::string HelpMessage(HelpMessageMode mode)
|
||||
_("If <category> is not supplied or if <category> = 1, output all debugging information.") + _("<category> can be:") + " " + debugCategories + ".");
|
||||
if (showDebug)
|
||||
strUsage += HelpMessageOpt("-nodebug", "Turn off debugging messages, same as -debug=0");
|
||||
strUsage += HelpMessageOpt("-gen", strprintf(_("Generate coins (default: %u)"), DEFAULT_GENERATE));
|
||||
strUsage += HelpMessageOpt("-genproclimit=<n>", strprintf(_("Set the number of threads for coin generation if enabled (-1 = all cores, default: %d)"), DEFAULT_GENERATE_THREADS));
|
||||
strUsage += HelpMessageOpt("-help-debug", _("Show all debugging options (usage: --help -help-debug)"));
|
||||
strUsage += HelpMessageOpt("-logips", strprintf(_("Include IP addresses in debug output (default: %u)"), DEFAULT_LOGIPS));
|
||||
strUsage += HelpMessageOpt("-logtimestamps", strprintf(_("Prepend debug output with timestamp (default: %u)"), DEFAULT_LOGTIMESTAMPS));
|
||||
@@ -1435,16 +1435,14 @@ bool AppInit2(Config& config, boost::thread_group& threadGroup, CScheduler& sche
|
||||
InitRespendFilter();
|
||||
StartNode(threadGroup, scheduler);
|
||||
|
||||
// Generate coins in the background
|
||||
GenerateBitcoins(GetBoolArg("-gen", DEFAULT_GENERATE), GetArg("-genproclimit", DEFAULT_GENERATE_THREADS), chainparams);
|
||||
#ifdef ENABLE_WALLET
|
||||
// Mine proof-of-stake blocks in the background
|
||||
if (!GetBoolArg("-staking", true))
|
||||
LogPrintf("Staking disabled\n");
|
||||
else if (pwalletMain)
|
||||
threadGroup.create_thread(boost::bind(&ThreadStakeMiner, pwalletMain, chainparams));
|
||||
// ********************************************************* Step 12: finished
|
||||
|
||||
// ********************************************************* Step 12: finished
|
||||
#endif
|
||||
SetRPCWarmupFinished();
|
||||
uiInterface.InitMessage(_("Done loading"));
|
||||
|
||||
Reference in New Issue
Block a user