test is_mine in add_keypairs_from_wallet
authorThomasV <thomasv@gitorious>
Sat, 21 Dec 2013 16:57:42 +0000 (17:57 +0100)
committerThomasV <thomasv@gitorious>
Sat, 21 Dec 2013 16:57:42 +0000 (17:57 +0100)
lib/wallet.py

index bed70ad..52d4285 100644 (file)
@@ -741,6 +741,8 @@ class Wallet:
     def add_keypairs_from_wallet(self, tx, keypairs, password):
         for txin in tx.inputs:
             address = txin['address']
+            if not self.is_mine(address):
+                continue
             private_keys = self.get_private_key(address, password)
             for sec in private_keys:
                 pubkey = public_key_from_private_key(sec)