mirror of
https://github.com/bitcoin/bitcoin.git
synced 2025-06-26 17:02:00 +02:00
Merge bitcoin/bitcoin#29400: test: Fix SegwitV0SignatureMsg nLockTime signedness
fab15723b0518acbb1015e64df47dcac0187e92f test: Fix SegwitV0SignatureMsg nLockTime signedness (MarcoFalke) Pull request description: It is unsigned in Bitcoin Core, so the tests should match it:5b8990a1f3/src/script/interpreter.cpp (L1611)
The bug was introduced when the code was written in 330b0f31ee5719d94f9e52dfc83c5d82168241f9. (Lowercase `i` means signed, see https://docs.python.org/3/library/struct.html#format-characters) ACKs for top commit: epiccurious: Tested ACK fab15723b0518acbb1015e64df47dcac0187e92f. Eunovo: Tested ACKfab15723b0
achow101: ACK fab15723b0518acbb1015e64df47dcac0187e92f Tree-SHA512: 68cb8582f6af22e6abb2fc9d6770277501baa0f9873e2e8d47699e87096fc5d4b9de45fa07199757b6e945c99d4c4ea95f01478322f2c093ef95cf5e0c78522b
This commit is contained in:
commit
88b1229c13
@ -747,7 +747,7 @@ def SegwitV0SignatureMsg(script, txTo, inIdx, hashtype, amount):
|
||||
ss += struct.pack("<q", amount)
|
||||
ss += struct.pack("<I", txTo.vin[inIdx].nSequence)
|
||||
ss += ser_uint256(hashOutputs)
|
||||
ss += struct.pack("<i", txTo.nLockTime)
|
||||
ss += txTo.nLockTime.to_bytes(4, "little")
|
||||
ss += struct.pack("<I", hashtype)
|
||||
return ss
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user