HomePhabricator

validation: No mempool clearing in UnloadBlockIndex

Description

validation: No mempool clearing in UnloadBlockIndex

Summary:
The only caller that uses this is ~ChainTestingSetup() where we
immediately destroy the mempool afterwards.

This is a partial backport of core#22564
https://github.com/bitcoin/bitcoin/pull/22564/commits/572d8319272ae84a81d6bfd53dd9685585697f65
https://github.com/bitcoin/bitcoin/pull/22564/commits/7d99d725cdb5428ed25dc07c2d7fddf420da7786

Note: the first commit is mostly not applicable to Bitcoin ABC, I mention it only because of the moving of ~ChainstateManager() from validation.h to validation.cpp. g_versionbitscache and warningcache are related to Core's BIP 9 and "buried deployments" business.

Depends on D13089

Test Plan: ninja all check-all

Reviewers: #bitcoin_abc, sdulfari

Reviewed By: #bitcoin_abc, sdulfari

Subscribers: sdulfari

Differential Revision: https://reviews.bitcoinabc.org/D13090

Details

Provenance
Carl Dong <contact@carldong.me>Authored on Jan 11 2022, 19:49
PiRKCommitted on Feb 2 2023, 11:30
PiRKPushed on Feb 2 2023, 11:30
Reviewer
Restricted Project
Differential Revision
D13090: validation: No mempool clearing in UnloadBlockIndex
Parents
rABC61adf21f6f41: style-only: Use std::clamp for check_ratio, rename
Branches
Unknown
Tags
Unknown