mirror of
https://github.com/bitcoin/bitcoin.git
synced 2025-11-12 15:09:59 +01:00
refactor: add unused ArgsManager to replace gArgs
This commit is contained in:
@@ -369,6 +369,7 @@ void SetupServerArgs(NodeContext& node)
|
||||
{
|
||||
assert(!node.args);
|
||||
node.args = &gArgs;
|
||||
ArgsManager& argsman = *node.args;
|
||||
|
||||
SetupHelpOptions(gArgs);
|
||||
gArgs.AddArg("-help-debug", "Print help message with debugging options and exit", ArgsManager::ALLOW_ANY, OptionsCategory::DEBUG_TEST); // server-only for now
|
||||
@@ -478,7 +479,7 @@ void SetupServerArgs(NodeContext& node)
|
||||
"CIDR-notated network (e.g. 1.2.3.0/24). Uses the same permissions as "
|
||||
"-whitebind. Can be specified multiple times." , ArgsManager::ALLOW_ANY, OptionsCategory::CONNECTION);
|
||||
|
||||
g_wallet_init_interface.AddWalletOptions();
|
||||
g_wallet_init_interface.AddWalletOptions(argsman);
|
||||
|
||||
#if ENABLE_ZMQ
|
||||
gArgs.AddArg("-zmqpubhashblock=<address>", "Enable publish hash block in <address>", ArgsManager::ALLOW_ANY, OptionsCategory::ZMQ);
|
||||
@@ -534,7 +535,7 @@ void SetupServerArgs(NodeContext& node)
|
||||
gArgs.AddArg("-shrinkdebugfile", "Shrink debug.log file on client startup (default: 1 when no -debug)", ArgsManager::ALLOW_ANY, OptionsCategory::DEBUG_TEST);
|
||||
gArgs.AddArg("-uacomment=<cmt>", "Append comment to the user agent string", ArgsManager::ALLOW_ANY, OptionsCategory::DEBUG_TEST);
|
||||
|
||||
SetupChainParamsBaseOptions();
|
||||
SetupChainParamsBaseOptions(argsman);
|
||||
|
||||
gArgs.AddArg("-acceptnonstdtxn", strprintf("Relay and mine \"non-standard\" transactions (%sdefault: %u)", "testnet/regtest only; ", !testnetChainParams->RequireStandard()), ArgsManager::ALLOW_ANY | ArgsManager::DEBUG_ONLY, OptionsCategory::NODE_RELAY);
|
||||
gArgs.AddArg("-incrementalrelayfee=<amt>", strprintf("Fee rate (in %s/kB) used to define cost of relay, used for mempool limiting and BIP 125 replacement. (default: %s)", CURRENCY_UNIT, FormatMoney(DEFAULT_INCREMENTAL_RELAY_FEE)), ArgsManager::ALLOW_ANY | ArgsManager::DEBUG_ONLY, OptionsCategory::NODE_RELAY);
|
||||
|
||||
Reference in New Issue
Block a user