diff options
author | Suhas Daftuar <sdaftuar@chaincode.com> | 2016-09-17 22:11:00 -0400 |
---|---|---|
committer | Wladimir J. van der Laan <laanwj@gmail.com> | 2016-10-13 20:09:31 +0200 |
commit | 611cc5096e5777502e18ba516d7a0eec93ac9c63 (patch) | |
tree | c08f496aa6e9c9a41fa524f8f47b9fbc4e61eede /qa/rpc-tests | |
parent | 61e282b62d7d4f0bca435c6e1b836d3b2c3a0874 (diff) | |
download | bitcoin-611cc5096e5777502e18ba516d7a0eec93ac9c63.tar.xz |
[qa] Fix bug in mininode witness deserialization
Also improve tx printing
Github-Pull: #8393
Rebased-From: f5b9b8f437c040205896ad0d7a6656efa08b5601
Diffstat (limited to 'qa/rpc-tests')
-rwxr-xr-x | qa/rpc-tests/test_framework/mininode.py | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/qa/rpc-tests/test_framework/mininode.py b/qa/rpc-tests/test_framework/mininode.py index b7e4737489..4d238c08d9 100755 --- a/qa/rpc-tests/test_framework/mininode.py +++ b/qa/rpc-tests/test_framework/mininode.py @@ -452,7 +452,7 @@ class CTransaction(object): else: self.vout = deser_vector(f, CTxOut) if flags != 0: - self.wit.vtxinwit = [CTxInWitness()]*len(self.vin) + self.wit.vtxinwit = [CTxInWitness() for i in range(len(self.vin))] self.wit.deserialize(f) self.nLockTime = struct.unpack("<I", f.read(4))[0] self.sha256 = None @@ -518,8 +518,8 @@ class CTransaction(object): return True def __repr__(self): - return "CTransaction(nVersion=%i vin=%s vout=%s nLockTime=%i)" \ - % (self.nVersion, repr(self.vin), repr(self.vout), self.nLockTime) + return "CTransaction(nVersion=%i vin=%s vout=%s wit=%s nLockTime=%i)" \ + % (self.nVersion, repr(self.vin), repr(self.vout), repr(self.wit), self.nLockTime) class CBlockHeader(object): |