aboutsummaryrefslogtreecommitdiff
path: root/src/warnings.cpp
diff options
context:
space:
mode:
authorWladimir J. van der Laan <laanwj@gmail.com>2018-04-27 17:03:33 +0200
committerWladimir J. van der Laan <laanwj@gmail.com>2018-04-27 17:03:44 +0200
commit17266a13067c061783e0428c6200985ed8872b16 (patch)
tree9b356c266f37bbc51432f1e00fb4ffe5d6f30aec /src/warnings.cpp
parent487dcbe80c20b53dadcc3e3265786d3d2f1f9490 (diff)
parentd8e9a2ac74e1071c9a92b9858b7ed3143413ee94 (diff)
downloadbitcoin-17266a13067c061783e0428c6200985ed8872b16.tar.xz
Merge #13090: Remove Safe mode (achow101)
d8e9a2a Remove "rpc" category from GetWarnings (Wladimir J. van der Laan) 7da3b0a rpc: Move RPC_FORBIDDEN_BY_SAFE_MODE code to reserved section (Wladimir J. van der Laan) 2ae705d Remove Safe mode (Andrew Chow) Pull request description: Rebase of #10563. Safe mode was [disabled by default and deprecated in 0.16](https://github.com/bitcoin/bitcoin/blob/master/doc/release-notes/release-notes-0.16.0.md#safe-mode-disabled-by-default), so probably should be removed for 0.17. > Rationale: > > Safe mode is useless. It only disables some RPC commands when large work forks are detected. Nothing else is affected by safe mode. It seems that very few people would be affected by safe mode. The people who use Core as a wallet are primarily using it through the GUI, which safe mode does not effect. In the GUI, transactions will still be made as normal; only a warning is displayed. > > I also don't think that we should be disabling RPC commands or any functionality in general. If we do, it should be done consistently, which safe mode is not. If we want to keep the idea of a safe mode around, I think that the current system needs to go first before a new system can be implemented. Tree-SHA512: 067938f47ca6e879fb6c3c4e21f9946fd7c5da3cde67ef436f1666798c78d049225b9111dc97064f42b3bc549d3915229fa19ad5a634588f381e34fc65d64044
Diffstat (limited to 'src/warnings.cpp')
-rw-r--r--src/warnings.cpp10
1 files changed, 2 insertions, 8 deletions
diff --git a/src/warnings.cpp b/src/warnings.cpp
index 572c766600..dc4e6e4842 100644
--- a/src/warnings.cpp
+++ b/src/warnings.cpp
@@ -40,7 +40,6 @@ void SetfLargeWorkInvalidChainFound(bool flag)
std::string GetWarnings(const std::string& strFor)
{
std::string strStatusBar;
- std::string strRPC;
std::string strGUI;
const std::string uiAlertSeperator = "<hr />";
@@ -51,9 +50,6 @@ std::string GetWarnings(const std::string& strFor)
strGUI = _("This is a pre-release test build - use at your own risk - do not use for mining or merchant applications");
}
- if (gArgs.GetBoolArg("-testsafemode", DEFAULT_TESTSAFEMODE))
- strStatusBar = strRPC = strGUI = "testsafemode enabled";
-
// Misc warnings like out of disk space and clock is wrong
if (strMiscWarning != "")
{
@@ -63,12 +59,12 @@ std::string GetWarnings(const std::string& strFor)
if (fLargeWorkForkFound)
{
- strStatusBar = strRPC = "Warning: The network does not appear to fully agree! Some miners appear to be experiencing issues.";
+ strStatusBar = "Warning: The network does not appear to fully agree! Some miners appear to be experiencing issues.";
strGUI += (strGUI.empty() ? "" : uiAlertSeperator) + _("Warning: The network does not appear to fully agree! Some miners appear to be experiencing issues.");
}
else if (fLargeWorkInvalidChainFound)
{
- strStatusBar = strRPC = "Warning: We do not appear to fully agree with our peers! You may need to upgrade, or other nodes may need to upgrade.";
+ strStatusBar = "Warning: We do not appear to fully agree with our peers! You may need to upgrade, or other nodes may need to upgrade.";
strGUI += (strGUI.empty() ? "" : uiAlertSeperator) + _("Warning: We do not appear to fully agree with our peers! You may need to upgrade, or other nodes may need to upgrade.");
}
@@ -76,8 +72,6 @@ std::string GetWarnings(const std::string& strFor)
return strGUI;
else if (strFor == "statusbar")
return strStatusBar;
- else if (strFor == "rpc")
- return strRPC;
assert(!"GetWarnings(): invalid parameter");
return "error";
}