1
0

If a transaction uses make_witness, also set script_sig.

Other methods (remove_signatures) may have set script_sig to None
during the lifetime of the tx object.
This commit is contained in:
ThomasV
2025-02-13 11:01:03 +01:00
parent b097150806
commit c3faadf23f

View File

@@ -2611,6 +2611,7 @@ class Abstract_Wallet(ABC, Logger, EventListener):
self.logger.info(f'sign_transaction: adding witness using make_witness')
privkey = txin.privkey
sig = tx.sign_txin(i, privkey)
txin.script_sig = b''
txin.witness = txin.make_witness(sig)
assert txin.is_complete()