MCPcopy Create free account
hub / github.com/BTCGPU/BTCGPU / NextSyncBlock

Function NextSyncBlock

src/index/base.cpp:68–82  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

66}
67
68static const CBlockIndex* NextSyncBlock(const CBlockIndex* pindex_prev)
69{
70 AssertLockHeld(cs_main);
71
72 if (!pindex_prev) {
73 return chainActive.Genesis();
74 }
75
76 const CBlockIndex* pindex = chainActive.Next(pindex_prev);
77 if (pindex) {
78 return pindex;
79 }
80
81 return chainActive.Next(chainActive.FindFork(pindex_prev));
82}
83
84void BaseIndex::ThreadSync()
85{

Callers 1

ThreadSyncMethod · 0.85

Calls 3

GenesisMethod · 0.80
FindForkMethod · 0.80
NextMethod · 0.45

Tested by

no test coverage detected