File tree Expand file tree Collapse file tree 1 file changed +4
-3
lines changed Expand file tree Collapse file tree 1 file changed +4
-3
lines changed Original file line number Diff line number Diff line change @@ -47,14 +47,15 @@ QList<TransactionRecord> TransactionRecord::decomposeTransaction(const CWallet *
47
47
//
48
48
// Credit
49
49
//
50
- BOOST_FOREACH ( const CTxOut& txout, wtx.tx ->vout )
50
+ for ( unsigned int i = 0 ; i < wtx.tx ->vout . size (); i++ )
51
51
{
52
+ const CTxOut& txout = wtx.tx ->vout [i];
52
53
isminetype mine = wallet->IsMine (txout);
53
54
if (mine)
54
55
{
55
56
TransactionRecord sub (hash, nTime);
56
57
CTxDestination address;
57
- sub.idx = parts. size () ; // sequence number
58
+ sub.idx = i ; // vout index
58
59
sub.credit = txout.nValue ;
59
60
sub.involvesWatchAddress = mine & ISMINE_WATCH_ONLY;
60
61
if (ExtractDestination (txout.scriptPubKey , address) && IsMine (*wallet, address))
@@ -118,7 +119,7 @@ QList<TransactionRecord> TransactionRecord::decomposeTransaction(const CWallet *
118
119
{
119
120
const CTxOut& txout = wtx.tx ->vout [nOut];
120
121
TransactionRecord sub (hash, nTime);
121
- sub.idx = parts. size () ;
122
+ sub.idx = nOut ;
122
123
sub.involvesWatchAddress = involvesWatchAddress;
123
124
124
125
if (wallet->IsMine (txout))
You can’t perform that action at this time.
0 commit comments