aboutsummaryrefslogtreecommitdiff
path: root/src/interfaces/chain.cpp
diff options
context:
space:
mode:
authorJames O'Beirne <[email protected]>2019-03-27 12:21:50 -0400
committerJames O'Beirne <[email protected]>2019-05-16 09:06:54 -0400
commit403e677c9ebbf9744733010e6b0c2d1b182ee850 (patch)
tree3c97f958fc6b15676945d55a82794366d3097fb6 /src/interfaces/chain.cpp
parentrefactoring: FlushStateToDisk -> CChainState (diff)
downloaddiscoin-403e677c9ebbf9744733010e6b0c2d1b182ee850.tar.xz
discoin-403e677c9ebbf9744733010e6b0c2d1b182ee850.zip
refactoring: IsInitialBlockDownload -> CChainState
We introduce CChainState.m_cached_finished_ibd because the static state it replaces would've been shared across all CChainState instances.
Diffstat (limited to 'src/interfaces/chain.cpp')
-rw-r--r--src/interfaces/chain.cpp4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/interfaces/chain.cpp b/src/interfaces/chain.cpp
index fcbc442d1..bc4be456b 100644
--- a/src/interfaces/chain.cpp
+++ b/src/interfaces/chain.cpp
@@ -321,8 +321,8 @@ public:
CFeeRate relayDustFee() override { return ::dustRelayFee; }
bool getPruneMode() override { return ::fPruneMode; }
bool p2pEnabled() override { return g_connman != nullptr; }
- bool isReadyToBroadcast() override { return !::fImporting && !::fReindex && !IsInitialBlockDownload(); }
- bool isInitialBlockDownload() override { return IsInitialBlockDownload(); }
+ bool isReadyToBroadcast() override { return !::fImporting && !::fReindex && !isInitialBlockDownload(); }
+ bool isInitialBlockDownload() override { return ::ChainstateActive().IsInitialBlockDownload(); }
bool shutdownRequested() override { return ShutdownRequested(); }
int64_t getAdjustedTime() override { return GetAdjustedTime(); }
void initMessage(const std::string& message) override { ::uiInterface.InitMessage(message); }