HomePhabricator

remove dead rpc code

Description

remove dead rpc code

Summary:
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)

This is a backport of core#18531 [1/2]
https://github.com/bitcoin/bitcoin/pull/18531/commits/fa19bb2cd8c575593583138a84e6bb3444d6196d

I confirmed with a grep that fHelp is not used in any other RPC command.

Depends on D10742

Test Plan: ninja all check-all

Reviewers: #bitcoin_abc, Fabien

Reviewed By: #bitcoin_abc, Fabien

Differential Revision: https://reviews.bitcoinabc.org/D10743

Details

Provenance
MarcoFalke <falke.marco@gmail.com>Authored on Sep 22 2020, 17:08
PiRKCommitted on Jan 3 2022, 14:06
PiRKPushed on Jan 3 2022, 14:07
Reviewer
Restricted Project
Differential Revision
D10743: remove dead rpc code
Parents
rABC3d7fdc544aab: Assert that RPCArg names are equal to CRPCCommand ones (abc, avalanche)
Branches
Unknown
Tags
Unknown

Event Timeline