mirror of
https://github.com/bitcoin/bitcoin.git
synced 2025-11-13 07:28:59 +01:00
validation: Move FindFilesToPrune{,Manual} to BlockManager
[META] No behaviour change is intended in this commit.
[META] This commit should be followed up by removing the comments and
assertions meant only to show that the change is correct.
Also stop FindFilesToPrune{,Manual} from unnecessary reaching for
::ChainActive() by passing in the necessary information.
This commit is contained in:
@@ -356,7 +356,15 @@ struct CBlockIndexWorkComparator
|
||||
* This data is used mostly in `CChainState` - information about, e.g.,
|
||||
* candidate tips is not maintained here.
|
||||
*/
|
||||
class BlockManager {
|
||||
class BlockManager
|
||||
{
|
||||
friend CChainState;
|
||||
|
||||
private:
|
||||
// See definition for documentation
|
||||
void FindFilesToPruneManual(std::set<int>& setFilesToPrune, int nManualPruneHeight, int chain_tip_height);
|
||||
void FindFilesToPrune(std::set<int>& setFilesToPrune, uint64_t nPruneAfterHeight, int chain_tip_height, bool is_ibd);
|
||||
|
||||
public:
|
||||
BlockMap m_block_index GUARDED_BY(cs_main);
|
||||
|
||||
|
||||
Reference in New Issue
Block a user