From b4b6988eb03cfc90332fbc82dec4e7e5d64b48be Mon Sep 17 00:00:00 2001 From: Duke Leto Date: Tue, 30 Aug 2022 21:05:27 -0400 Subject: [PATCH] Log when we use fee=0 for small inputs --- src/wallet/asyncrpcoperation_sweep.cpp | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/src/wallet/asyncrpcoperation_sweep.cpp b/src/wallet/asyncrpcoperation_sweep.cpp index b76915e92..721309385 100644 --- a/src/wallet/asyncrpcoperation_sweep.cpp +++ b/src/wallet/asyncrpcoperation_sweep.cpp @@ -197,9 +197,10 @@ bool AsyncRPCOperation_sweep::main_impl() { CAmount fee = fSweepTxFee; if (amountToSend <= fSweepTxFee) { - fee = 0; + LogPrintf("%s: Amount to send %s is <= fee, using fee=0", getId(), FormatMoney(amountToSend)); + fee = 0; } - amountSwept += amountToSend; + auto builder = TransactionBuilder(consensusParams, targetHeight_, pwalletMain); { LOCK2(cs_main, pwalletMain->cs_wallet);