aboutsummaryrefslogtreecommitdiff
path: root/src/wallet.cpp
diff options
context:
space:
mode:
authorRoss Nicoll <[email protected]>2014-04-13 00:07:06 +0100
committerRoss Nicoll <[email protected]>2014-04-13 00:07:06 +0100
commit71532b730d52ea578e947514d21fb5560e15d704 (patch)
tree20736bc5a1634aea1f6c6d10acb178f7e5bf96be /src/wallet.cpp
parentShifted unit in wallet tests from CENT to COIN as a base, to avoid problems w... (diff)
downloaddiscoin-71532b730d52ea578e947514d21fb5560e15d704.tar.xz
discoin-71532b730d52ea578e947514d21fb5560e15d704.zip
Reworked comment around the code for identifying transactions to spend, to separate explanation of condition, and result.
Corrected comment references to "cent", with "coin" in wallet tests, to match changes to units.
Diffstat (limited to 'src/wallet.cpp')
-rw-r--r--src/wallet.cpp7
1 files changed, 6 insertions, 1 deletions
diff --git a/src/wallet.cpp b/src/wallet.cpp
index 9c8e7d8bc..feeee86ce 100644
--- a/src/wallet.cpp
+++ b/src/wallet.cpp
@@ -1228,7 +1228,12 @@ bool CWallet::SelectCoinsMinConf(int64_t nTargetValue, int nConfMine, int nConfT
}
else if (n < nTargetValue + DUST_SOFT_LIMIT)
{
- // Skip coins which, if used, would result in less than a transaction fee in change
+ // This coin is not sufficient to cover the target plus change above the dust
+ // limit. The dust limit is important here, as we don't want to leave change
+ // which cannot be spent (is below the network transaction fee).
+
+ // Push the coin into an array for potential matching later, but keep trying to find
+ // an exact match
vValue.push_back(coin);
nTotalLower += n;
}