mirror of
https://github.com/bitcoin/bitcoin.git
synced 2025-12-13 22:24:05 +01:00
util, refactor: Use GetPathArg to read "-conf" value
Also "includeconf" values been normalized.
This commit is contained in:
@@ -801,7 +801,7 @@ static UniValue CallRPC(BaseRequestHandler* rh, const std::string& strMethod, co
|
||||
if (failedToGetAuthCookie) {
|
||||
throw std::runtime_error(strprintf(
|
||||
"Could not locate RPC credentials. No authentication cookie could be found, and RPC password is not set. See -rpcpassword and -stdinrpcpass. Configuration file: (%s)",
|
||||
fs::PathToString(GetConfigFile(gArgs.GetArg("-conf", BITCOIN_CONF_FILENAME)))));
|
||||
fs::PathToString(GetConfigFile(gArgs.GetPathArg("-conf", BITCOIN_CONF_FILENAME)))));
|
||||
} else {
|
||||
throw std::runtime_error("Authorization failed: Incorrect rpcuser or rpcpassword");
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user