Skip to content

Commit d103484

Browse files
committed
util: Do not use gArgs global in ArgsManager member functions
1 parent 875e1cc commit d103484

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

src/util/system.cpp

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -523,7 +523,7 @@ void ArgsManager::AddHiddenArgs(const std::vector<std::string>& names)
523523

524524
std::string ArgsManager::GetHelpMessage() const
525525
{
526-
const bool show_debug = gArgs.GetBoolArg("-help-debug", false);
526+
const bool show_debug = GetBoolArg("-help-debug", false);
527527

528528
std::string usage = "";
529529
LOCK(cs_args);
@@ -900,7 +900,7 @@ bool ArgsManager::ReadConfigFiles(std::string& error, bool ignore_invalid_keys)
900900
// If datadir is changed in .conf file:
901901
ClearDatadirCache();
902902
if (!CheckDataDirOption()) {
903-
error = strprintf("specified data directory \"%s\" does not exist.", gArgs.GetArg("-datadir", ""));
903+
error = strprintf("specified data directory \"%s\" does not exist.", GetArg("-datadir", ""));
904904
return false;
905905
}
906906
return true;

0 commit comments

Comments
 (0)