Skip to content

Commit 2f32c82

Browse files
committed
[Qt] show network/chain errors in the GUI
1 parent 8e048f4 commit 2f32c82

File tree

1 file changed

+5
-3
lines changed

1 file changed

+5
-3
lines changed

src/main.cpp

Lines changed: 5 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -4647,6 +4647,7 @@ std::string GetWarnings(const std::string& strFor)
46474647
string strStatusBar;
46484648
string strRPC;
46494649
string strGUI;
4650+
const string uiAlertSeperator = "<hr />";
46504651

46514652
if (!CLIENT_VERSION_IS_RELEASE) {
46524653
strStatusBar = "This is a pre-release test build - use at your own risk - do not use for mining or merchant applications";
@@ -4659,18 +4660,19 @@ std::string GetWarnings(const std::string& strFor)
46594660
// Misc warnings like out of disk space and clock is wrong
46604661
if (strMiscWarning != "")
46614662
{
4662-
strStatusBar = strGUI = strMiscWarning;
4663+
strStatusBar = strMiscWarning;
4664+
strGUI += (strGUI.empty() ? "" : uiAlertSeperator) + strMiscWarning;
46634665
}
46644666

46654667
if (fLargeWorkForkFound)
46664668
{
46674669
strStatusBar = strRPC = "Warning: The network does not appear to fully agree! Some miners appear to be experiencing issues.";
4668-
strGUI = _("Warning: The network does not appear to fully agree! Some miners appear to be experiencing issues.");
4670+
strGUI += strGUI.empty() ? "" : uiAlertSeperator + _("Warning: The network does not appear to fully agree! Some miners appear to be experiencing issues.");
46694671
}
46704672
else if (fLargeWorkInvalidChainFound)
46714673
{
46724674
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.";
4673-
strGUI = _("Warning: We do not appear to fully agree with our peers! You may need to upgrade, or other nodes may need to upgrade.");
4675+
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.");
46744676
}
46754677

46764678
if (strFor == "gui")

0 commit comments

Comments
 (0)