Merge pull request #808 from chrisrico/master

Trezor plugin fixes
This commit is contained in:
ThomasV 2014-08-28 22:33:41 +02:00
commit 107a0bd278
1 changed files with 7 additions and 7 deletions

View File

@ -262,17 +262,17 @@ class TrezorWallet(NewWallet):
for txinput in tx.inputs:
txinputtype = types.TxInputType()
address = txinput['address']
try:
address_path = self.address_id(address)
address_n = self.get_client().expand_path(address_path)
txinputtype.address_n.extend(address_n)
except: pass
if ('is_coinbase' in txinput and txinput['is_coinbase']):
prev_hash = "\0"*32
prev_index = 0xffffffff # signed int -1
else:
address = txinput['address']
try:
address_path = self.address_id(address)
address_n = self.get_client().expand_path(address_path)
txinputtype.address_n.extend(address_n)
except: pass
prev_hash = unhexlify(txinput['prevout_hash'])
prev_index = txinput['prevout_n']