diff options
author | MarcoFalke <falke.marco@gmail.com> | 2020-07-19 11:09:59 +0200 |
---|---|---|
committer | MarcoFalke <falke.marco@gmail.com> | 2020-09-05 11:44:25 +0200 |
commit | fa831684e54783f6b40533ca218eb7636bdae667 (patch) | |
tree | 7b016530828cf75ca24592efab81edaa96403649 /src/interfaces/chain.cpp | |
parent | df75e9f3ee4de2b841fe0e84514b58a4e630d258 (diff) | |
download | bitcoin-fa831684e54783f6b40533ca218eb7636bdae667.tar.xz |
refactor: Add IsRBFOptInEmptyMempool
Co-authored-by: John Newbery <jonnynewbs@gmail.com>
Diffstat (limited to 'src/interfaces/chain.cpp')
-rw-r--r-- | src/interfaces/chain.cpp | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/src/interfaces/chain.cpp b/src/interfaces/chain.cpp index 313c1265de..19de8ab202 100644 --- a/src/interfaces/chain.cpp +++ b/src/interfaces/chain.cpp @@ -276,8 +276,9 @@ public: } RBFTransactionState isRBFOptIn(const CTransaction& tx) override { - LOCK(::mempool.cs); - return IsRBFOptIn(tx, ::mempool); + if (!m_node.mempool) return IsRBFOptInEmptyMempool(tx); + LOCK(m_node.mempool->cs); + return IsRBFOptIn(tx, *m_node.mempool); } bool hasDescendantsInMempool(const uint256& txid) override { |