mirror of
https://github.com/LBRYFoundation/LBRY-Vault.git
synced 2025-08-28 16:01:30 +00:00
fix: transaction.parse_witness() for coinbase
This commit is contained in:
parent
1cbc794229
commit
32e88495ae
1 changed files with 3 additions and 1 deletions
|
@ -434,7 +434,9 @@ def parse_witness(vds, txin):
|
||||||
txin['value'] = vds.read_uint64()
|
txin['value'] = vds.read_uint64()
|
||||||
n = vds.read_compact_size()
|
n = vds.read_compact_size()
|
||||||
w = list(bh2u(vds.read_bytes(vds.read_compact_size())) for i in range(n))
|
w = list(bh2u(vds.read_bytes(vds.read_compact_size())) for i in range(n))
|
||||||
if n > 2:
|
if txin['type'] == 'coinbase':
|
||||||
|
pass
|
||||||
|
elif n > 2:
|
||||||
txin['num_sig'] = n - 2
|
txin['num_sig'] = n - 2
|
||||||
txin['signatures'] = parse_sig(w[1:-1])
|
txin['signatures'] = parse_sig(w[1:-1])
|
||||||
m, n, x_pubkeys, pubkeys, witnessScript = parse_redeemScript(bfh(w[-1]))
|
m, n, x_pubkeys, pubkeys, witnessScript = parse_redeemScript(bfh(w[-1]))
|
||||||
|
|
Loading…
Add table
Reference in a new issue