aboutsummaryrefslogtreecommitdiff
path: root/src/wallet.cpp
diff options
context:
space:
mode:
authorChris Moore <dooglus@gmail.com>2012-04-07 10:52:40 -0700
committerLuke Dashjr <luke-jr+git@utopios.org>2012-06-04 16:36:39 +0000
commite333ab56d5b9fd6b0510ef6b98caa8bfc5059082 (patch)
treef5c97d9e926002a326b1882a0187a875b75d430a /src/wallet.cpp
parent9b0369c773c1d350a05435d8d3ec4e954828fb82 (diff)
Move the random_shuffle call back into SelectCoinsMinConf() so we can unit test it.
Diffstat (limited to 'src/wallet.cpp')
-rw-r--r--src/wallet.cpp2
1 files changed, 2 insertions, 0 deletions
diff --git a/src/wallet.cpp b/src/wallet.cpp
index f7e931dbbb..36dbe7aeb1 100644
--- a/src/wallet.cpp
+++ b/src/wallet.cpp
@@ -926,6 +926,8 @@ bool CWallet::SelectCoinsMinConf(int64 nTargetValue, int nConfMine, int nConfThe
vector<pair<int64, pair<const CWalletTx*,unsigned int> > > vValue;
int64 nTotalLower = 0;
+ random_shuffle(vCoins.begin(), vCoins.end(), GetRandInt);
+
BOOST_FOREACH(COutput output, vCoins)
{
const CWalletTx *pcoin = output.tx;