HomePhabricator

refactor: Stop using gArgs global in system.cpp

Description

refactor: Stop using gArgs global in system.cpp

Summary:

refactor: Use new GetConfigFilePath function

https://github.com/bitcoin/bitcoin/pull/27170/commits/b20b34f5b33230fe253c81008496bd9b13fd6ecf

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.

https://github.com/bitcoin/bitcoin/pull/27170/commits/9a9d5da11fa6033f82dcf8e2298aee29587f5396

This is a backport of core#27170

Depends on D16193

Test Plan: ninja all check-all

Reviewers: #bitcoin_abc, Fabien

Reviewed By: #bitcoin_abc, Fabien

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

Details

Provenance
Ryan Ofsky <ryan@ofsky.org>Authored on Feb 27 2023, 19:14
PiRKCommitted on May 22 2024, 05:48
PiRKPushed on May 22 2024, 05:48
Reviewer
Restricted Project
Differential Revision
D16195: refactor: Stop using gArgs global in system.cpp
Parents
rABCf8f02358c908: util: make GetDataDir read-only & create datadir only in bitcoind and bitcoin-qt
Branches
Unknown
Tags
Unknown