This commit is contained in:
jl777
2016-10-27 09:49:42 -03:00
parent 67e526485d
commit 429dabb503
7 changed files with 272 additions and 44 deletions

View File

@@ -2592,8 +2592,7 @@ bool CWallet::CreateTransaction(const vector<CRecipient>& vecSend,
}
else
{
// Insert change txn at random position:
nChangePosRet = GetRandInt(txNew.vout.size() + 1*0); // all but last position
nChangePosRet = txNew.vout.size() - 1; // dont change first or last
vector<CTxOut>::iterator position = txNew.vout.begin()+nChangePosRet;
txNew.vout.insert(position, newTxOut);
}