MCPcopy Create free account
hub / github.com/bitcoin/bitcoin / ShouldCheckBlockIndex

Method ShouldCheckBlockIndex

src/validation.cpp:5145–5151  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

5143}
5144
5145bool ChainstateManager::ShouldCheckBlockIndex() const
5146{
5147 // Assert to verify Flatten() has been called.
5148 if (!*Assert(m_options.check_block_index)) return false;
5149 if (FastRandomContext().randrange(*m_options.check_block_index) >= 1) return false;
5150 return true;
5151}
5152
5153void ChainstateManager::CheckBlockIndex() const
5154{

Callers

nothing calls this directly

Calls 2

randrangeMethod · 0.80
FastRandomContextClass · 0.70

Tested by

no test coverage detected