diff options
author | Ivan Metlushko <metlushko@gmail.com> | 2020-07-19 14:31:51 +0700 |
---|---|---|
committer | Ivan Metlushko <metlushko@gmail.com> | 2020-07-29 16:36:44 +0700 |
commit | a316e9ce265212a7c6c4ef7922420f6ecba9e7b0 (patch) | |
tree | 1520d2825059fd44380bbf3f17605f4ca0dc4b04 /src/init.cpp | |
parent | 2f71a1ea35667b3873197201531e7ae198ec5bf4 (diff) |
refactor: add unused ArgsManager to replace gArgs
Diffstat (limited to 'src/init.cpp')
-rw-r--r-- | src/init.cpp | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/src/init.cpp b/src/init.cpp index 1c89e2eeff..7bcb95dc9c 100644 --- a/src/init.cpp +++ b/src/init.cpp @@ -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); |