From 36d8ef6b7b1e0da771c475c7ad2ab7fab60bcb2e Mon Sep 17 00:00:00 2001 From: Michael Toutonghi Date: Sat, 2 Jun 2018 23:01:58 -0700 Subject: [PATCH] Fix "setgenerate true 0" to properly stake --- src/rpcmining.cpp | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/rpcmining.cpp b/src/rpcmining.cpp index c9bbd967d..f475a4258 100644 --- a/src/rpcmining.cpp +++ b/src/rpcmining.cpp @@ -32,7 +32,7 @@ using namespace std; -extern int32_t ASSETCHAINS_ALGO, ASSETCHAINS_EQUIHASH; +extern int32_t ASSETCHAINS_ALGO, ASSETCHAINS_EQUIHASH, ASSETCHAINS_LWMAPOS; /** * Return average network hashes per second based on the last 'lookup' blocks, @@ -320,7 +320,7 @@ UniValue setgenerate(const UniValue& params, bool fHelp) if (params.size() > 1) { nGenProcLimit = params[1].get_int(); - if (nGenProcLimit == 0) + if (ASSETCHAINS_LWMAPOS == 0 && nGenProcLimit == 0) fGenerate = false; }