diff --git a/src/miner.cpp b/src/miner.cpp index 1327c053f..e88ce4ac4 100644 --- a/src/miner.cpp +++ b/src/miner.cpp @@ -1911,13 +1911,27 @@ void static BitcoinMiner() libzcash::PaymentAddress addr = DecodePaymentAddress(VERUS_CHEATCATCHER); if (VERUS_CHEATCATCHER.size() > 0 && IsValidPaymentAddress(addr)) { - cheatCatcher = boost::get(addr); + try + { + cheatCatcher = boost::get(addr); + } + catch (...) + { + } } - else + if (VERUS_CHEATCATCHER.size() > 0) { - if (VERUS_CHEATCATCHER.size() > 0) + if (cheatCatcher == boost::none) + { + LogPrintf("ERROR: -cheatcatcher parameter is invalid Sapling payment address\n"); fprintf(stderr, "-cheatcatcher parameter is invalid Sapling payment address\n"); - } + } + else + { + LogPrintf("Cheat Catcher active on %s\n", VERUS_CHEATCATCHER.c_str()); + fprintf(stderr, "Cheat Catcher active on %s\n", VERUS_CHEATCATCHER.c_str()); + } + } static boost::thread_group* minerThreads = NULL;