From bdc6628683197945326cbdfea3f53ec0b7d1949f Mon Sep 17 00:00:00 2001 From: Russell Yanofsky Date: Fri, 28 Jul 2017 19:25:26 -0400 Subject: Remove use of IsRBFOptIn in wallet code This commit does not change behavior. --- src/interfaces/chain.cpp | 7 +++++++ src/interfaces/chain.h | 6 +++++- 2 files changed, 12 insertions(+), 1 deletion(-) (limited to 'src/interfaces') diff --git a/src/interfaces/chain.cpp b/src/interfaces/chain.cpp index c7c2d4e91c..7cab303aad 100644 --- a/src/interfaces/chain.cpp +++ b/src/interfaces/chain.cpp @@ -6,9 +6,11 @@ #include #include +#include #include #include #include +#include #include #include #include @@ -183,6 +185,11 @@ public: LOCK(cs_main); return GuessVerificationProgress(Params().TxData(), LookupBlockIndex(block_hash)); } + RBFTransactionState isRBFOptIn(const CTransaction& tx) override + { + LOCK(::mempool.cs); + return IsRBFOptIn(tx, ::mempool); + } }; } // namespace diff --git a/src/interfaces/chain.h b/src/interfaces/chain.h index 453938751d..486f1ea169 100644 --- a/src/interfaces/chain.h +++ b/src/interfaces/chain.h @@ -5,7 +5,8 @@ #ifndef BITCOIN_INTERFACES_CHAIN_H #define BITCOIN_INTERFACES_CHAIN_H -#include +#include // For Optional and nullopt +#include // For RBFTransactionState #include #include @@ -131,6 +132,9 @@ public: //! Estimate fraction of total transactions verified if blocks up to //! the specified block hash are verified. virtual double guessVerificationProgress(const uint256& block_hash) = 0; + + //! Check if transaction is RBF opt in. + virtual RBFTransactionState isRBFOptIn(const CTransaction& tx) = 0; }; //! Interface to let node manage chain clients (wallets, or maybe tools for -- cgit v1.2.3