mirror of
https://github.com/bitcoin/bitcoin.git
synced 2026-01-20 07:09:15 +01:00
util: Make util/error bilingual_str (refactor)
Translated strings should not end up in the debug log, stderr, or returned by an RPC. Changing the util methods in util/error to return a bilingual_str paves the way to achieve this goal in the long term.
This commit is contained in:
@@ -1060,7 +1060,7 @@ bool AppInitParameterInteraction()
|
||||
{
|
||||
CAmount n = 0;
|
||||
if (!ParseMoney(gArgs.GetArg("-incrementalrelayfee", ""), n))
|
||||
return InitError(AmountErrMsg("incrementalrelayfee", gArgs.GetArg("-incrementalrelayfee", "")));
|
||||
return InitError(AmountErrMsg("incrementalrelayfee", gArgs.GetArg("-incrementalrelayfee", "")).translated);
|
||||
incrementalRelayFee = CFeeRate(n);
|
||||
}
|
||||
|
||||
@@ -1104,7 +1104,7 @@ bool AppInitParameterInteraction()
|
||||
if (gArgs.IsArgSet("-minrelaytxfee")) {
|
||||
CAmount n = 0;
|
||||
if (!ParseMoney(gArgs.GetArg("-minrelaytxfee", ""), n)) {
|
||||
return InitError(AmountErrMsg("minrelaytxfee", gArgs.GetArg("-minrelaytxfee", "")));
|
||||
return InitError(AmountErrMsg("minrelaytxfee", gArgs.GetArg("-minrelaytxfee", "")).translated);
|
||||
}
|
||||
// High fee check is done afterward in WalletParameterInteraction()
|
||||
::minRelayTxFee = CFeeRate(n);
|
||||
@@ -1120,7 +1120,7 @@ bool AppInitParameterInteraction()
|
||||
{
|
||||
CAmount n = 0;
|
||||
if (!ParseMoney(gArgs.GetArg("-blockmintxfee", ""), n))
|
||||
return InitError(AmountErrMsg("blockmintxfee", gArgs.GetArg("-blockmintxfee", "")));
|
||||
return InitError(AmountErrMsg("blockmintxfee", gArgs.GetArg("-blockmintxfee", "")).translated);
|
||||
}
|
||||
|
||||
// Feerate used to define dust. Shouldn't be changed lightly as old
|
||||
@@ -1129,7 +1129,7 @@ bool AppInitParameterInteraction()
|
||||
{
|
||||
CAmount n = 0;
|
||||
if (!ParseMoney(gArgs.GetArg("-dustrelayfee", ""), n))
|
||||
return InitError(AmountErrMsg("dustrelayfee", gArgs.GetArg("-dustrelayfee", "")));
|
||||
return InitError(AmountErrMsg("dustrelayfee", gArgs.GetArg("-dustrelayfee", "")).translated);
|
||||
dustRelayFee = CFeeRate(n);
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user