diff --git a/src/wallet/wallet.cpp b/src/wallet/wallet.cpp --- a/src/wallet/wallet.cpp +++ b/src/wallet/wallet.cpp @@ -4807,11 +4807,6 @@ bool CWalletTx::AcceptToMemoryPool(const Amount nAbsurdFee, CValidationState &state) { - // Quick check to avoid re-setting fInMempool to false - if (g_mempool.exists(tx->GetId())) { - return false; - } - // We must set fInMempool here - while it will be re-set to true by the // entered-mempool callback, if we did not there would be a race where a // user could call sendmoney in a loop and hit spurious out of funds errors @@ -4821,7 +4816,7 @@ GetConfig(), g_mempool, state, tx, true /* fLimitFree */, nullptr /* pfMissingInputs */, false /* fOverrideMempoolLimit */, nAbsurdFee); - fInMempool = ret; + fInMempool |= ret; return ret; }