Page MenuHomePhabricator

test/fuzz: Invoke LoadMempool via Chainstate
ClosedPublic

Authored by PiRK on Mar 18 2024, 13:41.

Details

Reviewers
Fabien
Group Reviewers
Restricted Project
Commits
rABC94e3f92a3f83: test/fuzz: Invoke LoadMempool via Chainstate
Summary

Not only does this increase coverage, it is also more correct in that
when ::LoadMempool is called with a mempool and chainstate, it calls
AcceptToMemoryPool with just the chainstate.

AcceptToMemoryPool will then act on the chainstate's mempool via
CChainState::GetMempool, which may be different from the mempool
originally passed to ::LoadMempool. (In this fuzz test's case, it
definitely is different)

This is a partial backport of core#25478
https://github.com/bitcoin/bitcoin/pull/25487/commits/b857ac60d9a0433036519c26675378bbf56a1de1

Depends on D15720

Test Plan

ninja all check-all bitcoin-fuzzers