Browse Source

do not create change addresses in this thread; synchronize() should be sufficient

283
ThomasV 13 years ago
parent
commit
754fdcfa50
  1. 11
      client/electrum.py

11
client/electrum.py

@ -632,15 +632,8 @@ class Wallet:
outputs = [ (to_addr, amount) ]
change_amount = total - ( amount + fee )
if change_amount != 0:
# first look for unused change addresses
for addr in self.change_addresses:
if self.history.get(addr): continue
change_address = addr
break
else:
change_address = self.create_new_address2(True)
print "new change address", change_address
outputs.append( (change_address, change_amount) )
# normally, the update thread should ensure that the last change address is unused
outputs.append( ( self.change_addresses[-1], change_amount) )
return outputs
def sign_inputs( self, inputs, outputs, password ):

Loading…
Cancel
Save