Skip to content

Commit

Permalink
[Wallet] Write new transactions to wtxOrdered properly
Browse files Browse the repository at this point in the history
This addresses an issue where new incoming transactions aren't recorded,
 and subsequently, not returned with `listtransactions` in the same
 session.
  • Loading branch information
Fuzzbawls committed May 3, 2018
1 parent 084c10d commit b2fdbbf
Showing 1 changed file with 1 addition and 0 deletions.
1 change: 1 addition & 0 deletions src/wallet.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -659,6 +659,7 @@ bool CWallet::AddToWallet(const CWalletTx& wtxIn, bool fFromLoadWallet)
if (!wtx.nTimeReceived)
wtx.nTimeReceived = GetAdjustedTime();
wtx.nOrderPos = IncOrderPosNext();
wtxOrdered.insert(make_pair(wtx.nOrderPos, TxPair(&wtx, (CAccountingEntry*)0)));
wtx.nTimeSmart = ComputeTimeSmart(wtx);
AddToSpends(hash);
}
Expand Down

0 comments on commit b2fdbbf

Please sign in to comment.