From 7da4a8ffb3c9807c59f8ba63781169e4045594ba Mon Sep 17 00:00:00 2001 From: James O'Beirne Date: Fri, 3 Dec 2021 10:34:07 -0500 Subject: cover DisconnectBlock with lock annotation CoinsTip() access requires cs_main and therefore so should this function. --- src/validation.h | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) (limited to 'src/validation.h') diff --git a/src/validation.h b/src/validation.h index 9385dfdab4..2609538ece 100644 --- a/src/validation.h +++ b/src/validation.h @@ -718,7 +718,8 @@ public: bool AcceptBlock(const std::shared_ptr& pblock, BlockValidationState& state, CBlockIndex** ppindex, bool fRequested, const FlatFilePos* dbp, bool* fNewBlock) EXCLUSIVE_LOCKS_REQUIRED(cs_main); // Block (dis)connection on a given view: - DisconnectResult DisconnectBlock(const CBlock& block, const CBlockIndex* pindex, CCoinsViewCache& view); + DisconnectResult DisconnectBlock(const CBlock& block, const CBlockIndex* pindex, CCoinsViewCache& view) + EXCLUSIVE_LOCKS_REQUIRED(::cs_main); bool ConnectBlock(const CBlock& block, BlockValidationState& state, CBlockIndex* pindex, CCoinsViewCache& view, bool fJustCheck = false) EXCLUSIVE_LOCKS_REQUIRED(cs_main); -- cgit v1.2.3