diff options
author | MacroFake <falke.marco@gmail.com> | 2022-07-20 18:16:30 +0200 |
---|---|---|
committer | MacroFake <falke.marco@gmail.com> | 2022-10-18 14:07:59 +0200 |
commit | faf44876db555f7488c8df96db9fa88b793f897c (patch) | |
tree | 4db52179a2539d5ab6fcd7cf21a3ddeef2aed2f6 /src/kernel/chainstatemanager_opts.h | |
parent | ba441d493ce6543c63c923596004b7ce0409cba2 (diff) |
Move ::nMaxTipAge into ChainstateManager
Diffstat (limited to 'src/kernel/chainstatemanager_opts.h')
-rw-r--r-- | src/kernel/chainstatemanager_opts.h | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/src/kernel/chainstatemanager_opts.h b/src/kernel/chainstatemanager_opts.h index 520d0e8e75..ab3ea254ba 100644 --- a/src/kernel/chainstatemanager_opts.h +++ b/src/kernel/chainstatemanager_opts.h @@ -12,6 +12,8 @@ class CChainParams; +static constexpr auto DEFAULT_MAX_TIP_AGE{24h}; + namespace kernel { /** @@ -22,6 +24,8 @@ namespace kernel { struct ChainstateManagerOpts { const CChainParams& chainparams; const std::function<NodeClock::time_point()> adjusted_time_callback{nullptr}; + //! If the tip is older than this, the node is considered to be in initial block download. + std::chrono::seconds max_tip_age{DEFAULT_MAX_TIP_AGE}; }; } // namespace kernel |