mirror of
https://github.com/bitcoin/bitcoin.git
synced 2025-06-30 02:31:05 +02:00
test: Correctly deserialize without witness
This commit is contained in:
@ -450,6 +450,8 @@ class CTransaction:
|
|||||||
if flags != 0:
|
if flags != 0:
|
||||||
self.wit.vtxinwit = [CTxInWitness() for i in range(len(self.vin))]
|
self.wit.vtxinwit = [CTxInWitness() for i in range(len(self.vin))]
|
||||||
self.wit.deserialize(f)
|
self.wit.deserialize(f)
|
||||||
|
else:
|
||||||
|
self.wit = CTxWitness()
|
||||||
self.nLockTime = struct.unpack("<I", f.read(4))[0]
|
self.nLockTime = struct.unpack("<I", f.read(4))[0]
|
||||||
self.sha256 = None
|
self.sha256 = None
|
||||||
self.hash = None
|
self.hash = None
|
||||||
|
Reference in New Issue
Block a user