diff options
| author | Satoshi Nakamoto <[email protected]> | 2010-08-28 00:51:52 +0000 |
|---|---|---|
| committer | Gavin Andresen <[email protected]> | 2010-08-28 00:51:52 +0000 |
| commit | 522dfe3422f562368ebdaeb2b1a13cc9ebafa333 (patch) | |
| tree | 8192a067d01da6c5f9dbe38e4f9ac5459eb336f1 /rpc.cpp | |
| parent | warning message if clock is too far off (diff) | |
| download | discoin-522dfe3422f562368ebdaeb2b1a13cc9ebafa333.tar.xz discoin-522dfe3422f562368ebdaeb2b1a13cc9ebafa333.zip | |
alert system
-- version 0.3.11
Diffstat (limited to 'rpc.cpp')
| -rw-r--r-- | rpc.cpp | 7 |
1 files changed, 4 insertions, 3 deletions
@@ -247,7 +247,7 @@ Value getinfo(const Array& params, bool fHelp) obj.push_back(Pair("genproclimit", (int)(fLimitProcessors ? nLimitProcessors : -1))); obj.push_back(Pair("difficulty", (double)GetDifficulty())); obj.push_back(Pair("hashespersec", gethashespersec(params, false))); - obj.push_back(Pair("status", strWarning)); + obj.push_back(Pair("errors", GetWarnings("statusbar"))); return obj; } @@ -975,8 +975,9 @@ void ThreadRPCServer2(void* parg) printf("ThreadRPCServer method=%s\n", strMethod.c_str()); // Observe lockdown - if (IsLockdown() && !mapArgs.count("-overridesafety") && strMethod != "help" && strMethod != "stop" && strMethod != "getgenerate" && strMethod != "setgenerate") - throw runtime_error("WARNING: Displayed transactions may not be correct! You may need to upgrade, or other nodes may need to upgrade."); + string strWarning = GetWarnings("rpc"); + if (strWarning != "" && !mapArgs.count("-overridesafety") && strMethod != "getinfo" && strMethod != "help" && strMethod != "stop" && strMethod != "getgenerate" && strMethod != "setgenerate") + throw runtime_error(strWarning); // Execute map<string, rpcfn_type>::iterator mi = mapCallTable.find(strMethod); |