Skip to content

Commit

Permalink
Merge pull request #3634 from achow101/avoid-list-mod
Browse files Browse the repository at this point in the history
Avoid modifying self.transactions in prepare_for_verifier
  • Loading branch information
ecdsa committed Jan 2, 2018
2 parents 7ae1a4c + 0a83b3a commit 1cc7e61
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion lib/wallet.py
Original file line number Diff line number Diff line change
Expand Up @@ -969,7 +969,7 @@ def prepare_for_verifier(self):
# if we are on a pruning server, remove unverified transactions
with self.lock:
vr = list(self.verified_tx.keys()) + list(self.unverified_tx.keys())
for tx_hash in self.transactions.keys():
for tx_hash in list(self.transactions):
if tx_hash not in vr:
self.print_error("removing transaction", tx_hash)
self.transactions.pop(tx_hash)
Expand Down

0 comments on commit 1cc7e61

Please sign in to comment.