From fa19bb2cd8c575593583138a84e6bb3444d6196d Mon Sep 17 00:00:00 2001 From: MarcoFalke Date: Tue, 22 Sep 2020 19:08:36 +0200 Subject: remove dead rpc code Checking for fHelp, or the size of the args, is dead code because: * fHelp is always false (src/qt/test/rpcnestedtests.cpp) * It is already implicitly called by RPCHelpMan::Check (src/rpc/mining.cpp, src/rpc/misc.cpp, src/rpc/net.cpp) --- src/rpc/misc.cpp | 2 -- 1 file changed, 2 deletions(-) (limited to 'src/rpc/misc.cpp') diff --git a/src/rpc/misc.cpp b/src/rpc/misc.cpp index 0c982317f5..b3102a236d 100644 --- a/src/rpc/misc.cpp +++ b/src/rpc/misc.cpp @@ -624,8 +624,6 @@ static RPCHelpMan echo(const std::string& name) RPCExamples{""}, [&](const RPCHelpMan& self, const JSONRPCRequest& request) -> UniValue { - if (request.fHelp) throw std::runtime_error(self.ToString()); - if (request.params[9].isStr()) { CHECK_NONFATAL(request.params[9].get_str() != "trigger_internal_bug"); } -- cgit v1.2.3