aboutsummaryrefslogtreecommitdiff
path: root/src/qt
diff options
context:
space:
mode:
authorJonas Schnelli <dev@jonasschnelli.ch>2016-01-08 11:03:52 +0100
committerJonas Schnelli <dev@jonasschnelli.ch>2016-01-08 11:18:28 +0100
commit8a7f0001be88122256b1a8dc29b066210dc85625 (patch)
tree02d35c01a5d68c8aa54662cbf0f0acec0681f1f2 /src/qt
parentdb198d51a651086744871c972637f3856675a2ed (diff)
downloadbitcoin-8a7f0001be88122256b1a8dc29b066210dc85625.tar.xz
[RPC] remove the option of having multiple timer interfaces
Diffstat (limited to 'src/qt')
-rw-r--r--src/qt/rpcconsole.cpp6
1 files changed, 4 insertions, 2 deletions
diff --git a/src/qt/rpcconsole.cpp b/src/qt/rpcconsole.cpp
index 4c869b9ac5..7178bc00e6 100644
--- a/src/qt/rpcconsole.cpp
+++ b/src/qt/rpcconsole.cpp
@@ -278,7 +278,9 @@ RPCConsole::RPCConsole(const PlatformStyle *platformStyle, QWidget *parent) :
#endif
// Register RPC timer interface
rpcTimerInterface = new QtRPCTimerInterface();
- RPCRegisterTimerInterface(rpcTimerInterface);
+ // avoid accidentally overwriting an existing, non QTThread
+ // based timer interface
+ RPCSetTimerInterfaceIfUnset(rpcTimerInterface);
startExecutor();
setTrafficGraphRange(INITIAL_TRAFFIC_GRAPH_MINS);
@@ -293,7 +295,7 @@ RPCConsole::~RPCConsole()
{
GUIUtil::saveWindowGeometry("nRPCConsoleWindow", this);
Q_EMIT stopExecutor();
- RPCUnregisterTimerInterface(rpcTimerInterface);
+ RPCUnsetTimerInterface(rpcTimerInterface);
delete rpcTimerInterface;
delete ui;
}