postpone x_pubkeys replacement (fix #2738)

This commit is contained in:
ThomasV 2017-08-27 14:03:53 +02:00
parent 2e567fc86a
commit 88bbaf0950
1 changed files with 2 additions and 2 deletions

View File

@ -566,7 +566,7 @@ class Transaction:
j = pubkeys.index(pubkey)
print_error("adding sig", i, j, pubkey, sig)
self._inputs[i]['signatures'][j] = sig
self._inputs[i]['x_pubkeys'][j] = pubkey
#self._inputs[i]['x_pubkeys'][j] = pubkey
break
# redo raw
self.raw = self.serialize()
@ -831,7 +831,7 @@ class Transaction:
sig = private_key.sign_digest_deterministic(pre_hash, hashfunc=hashlib.sha256, sigencode = ecdsa.util.sigencode_der)
assert public_key.verify_digest(sig, pre_hash, sigdecode = ecdsa.util.sigdecode_der)
txin['signatures'][j] = bh2u(sig) + '01'
txin['x_pubkeys'][j] = pubkey
#txin['x_pubkeys'][j] = pubkey
txin['pubkeys'][j] = pubkey # needed for fd keys
self._inputs[i] = txin
print_error("is_complete", self.is_complete())