diff options
author | fanquake <fanquake@gmail.com> | 2021-08-18 13:37:27 +0800 |
---|---|---|
committer | fanquake <fanquake@gmail.com> | 2021-08-18 13:54:09 +0800 |
commit | f68c6cebe638cc3cf92f4e37650d37ea3899893a (patch) | |
tree | 40391412253fb552ae2550fa56f8df369b2f58b7 /src/net.cpp | |
parent | b5c468cfe35e5b24b14b03ff91fe1a4e72ce53f6 (diff) | |
download | bitcoin-f68c6cebe638cc3cf92f4e37650d37ea3899893a.tar.xz |
net: use clientInterface rather than uiInterface
Diffstat (limited to 'src/net.cpp')
-rw-r--r-- | src/net.cpp | 11 |
1 files changed, 8 insertions, 3 deletions
diff --git a/src/net.cpp b/src/net.cpp index 8ef770ede2..c669d187f3 100644 --- a/src/net.cpp +++ b/src/net.cpp @@ -1304,8 +1304,9 @@ void CConnman::NotifyNumConnectionsChanged() } if(vNodesSize != nPrevNodeCount) { nPrevNodeCount = vNodesSize; - if(clientInterface) + if (clientInterface) { clientInterface->NotifyNumConnectionsChanged(vNodesSize); + } } } @@ -2448,7 +2449,9 @@ void CConnman::SetNetworkActive(bool active) fNetworkActive = active; - uiInterface.NotifyNetworkActiveChanged(fNetworkActive); + if (clientInterface) { + clientInterface->NotifyNetworkActiveChanged(fNetworkActive); + } } CConnman::CConnman(uint64_t nSeed0In, uint64_t nSeed1In, CAddrMan& addrman_in, bool network_active) @@ -2556,7 +2559,9 @@ bool CConnman::Start(CScheduler& scheduler, const Options& connOptions) LogPrintf("%i block-relay-only anchors will be tried for connections.\n", m_anchors.size()); } - uiInterface.InitMessage(_("Starting network threads…").translated); + if (clientInterface) { + clientInterface->InitMessage(_("Starting network threads…").translated); + } fAddressesInitialized = true; |