Skip to content

Commit 0aeab14

Browse files
luke-jrinstagibbs
authored andcommitted
GUI: Ignore explicit fee output when determining if a transaction is send-to-self
1 parent 1655947 commit 0aeab14

File tree

1 file changed

+7
-2
lines changed

1 file changed

+7
-2
lines changed

src/qt/transactionrecord.cpp

Lines changed: 7 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -85,8 +85,13 @@ QList<TransactionRecord> TransactionRecord::decomposeTransaction(const interface
8585
}
8686

8787
isminetype fAllToMe = ISMINE_SPENDABLE;
88-
for (const isminetype mine : wtx.txout_is_mine)
89-
{
88+
for (unsigned int i = 0; i < wtx.txout_is_mine.size(); ++i) {
89+
const isminetype mine = wtx.txout_is_mine[i];
90+
const CTxOut txout = wtx.tx->vout[i];
91+
if (txout.IsFee()) {
92+
// explicit fee; ignore
93+
continue;
94+
}
9095
if(mine & ISMINE_WATCH_ONLY) involvesWatchAddress = true;
9196
if(fAllToMe > mine) fAllToMe = mine;
9297
}

0 commit comments

Comments
 (0)