|
|
@ -1633,6 +1633,9 @@ CAmount CWallet::GetMinimumFee(unsigned int nTxBytes, unsigned int nConfirmTarge |
|
|
|
{ |
|
|
|
{ |
|
|
|
// payTxFee is user-set "I want to pay this much"
|
|
|
|
// payTxFee is user-set "I want to pay this much"
|
|
|
|
CAmount nFeeNeeded = payTxFee.GetFee(nTxBytes); |
|
|
|
CAmount nFeeNeeded = payTxFee.GetFee(nTxBytes); |
|
|
|
|
|
|
|
// prevent user from paying a non-sense fee (like 1 satoshi): 0 < fee < minRelayFee
|
|
|
|
|
|
|
|
if (nFeeNeeded > 0 && nFeeNeeded < ::minRelayTxFee.GetFee(nTxBytes)) |
|
|
|
|
|
|
|
nFeeNeeded = ::minRelayTxFee.GetFee(nTxBytes); |
|
|
|
// User didn't set: use -txconfirmtarget to estimate...
|
|
|
|
// User didn't set: use -txconfirmtarget to estimate...
|
|
|
|
if (nFeeNeeded == 0) |
|
|
|
if (nFeeNeeded == 0) |
|
|
|
nFeeNeeded = pool.estimateFee(nConfirmTarget).GetFee(nTxBytes); |
|
|
|
nFeeNeeded = pool.estimateFee(nConfirmTarget).GetFee(nTxBytes); |
|
|
|