mirror of
https://github.com/bitcoin/bitcoin.git
synced 2025-11-11 14:38:29 +01:00
refactor: Stop using gArgs global in system.cpp
Most of the code in util/system.cpp that was hardcoded to use the global ArgsManager instance `gArgs` has been changed to work with explicit ArgsManager instances (for example in https://github.com/bitcoin/bitcoin/pull/20092). But a few hardcoded references to `gArgs` remain. This commit removes the last ones so these functions aren't reading or writing global state.
This commit is contained in:
@@ -148,7 +148,7 @@ static const char* BITCOIN_PID_FILENAME = "bitcoind.pid";
|
||||
|
||||
static fs::path GetPidFile(const ArgsManager& args)
|
||||
{
|
||||
return AbsPathForConfigVal(args.GetPathArg("-pid", BITCOIN_PID_FILENAME));
|
||||
return AbsPathForConfigVal(args, args.GetPathArg("-pid", BITCOIN_PID_FILENAME));
|
||||
}
|
||||
|
||||
[[nodiscard]] static bool CreatePidFile(const ArgsManager& args)
|
||||
|
||||
Reference in New Issue
Block a user