Skip to content

Commit efcfe8b

Browse files
authored
Merge pull request bitcoin#782 from MarcoFalke/patch-1
BIP 144: Old serialization format must be used on empty witness
2 parents 673feb8 + d8dea4e commit efcfe8b

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

bip-0144.mediawiki

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -79,7 +79,7 @@ The serialization has the following structure:
7979

8080
Parsers supporting this BIP will be able to distinguish between the old serialization format (without the witness) and this one. The marker byte is set to zero so that this structure will never parse as a valid transaction in a parser that does not support this BIP. If parsing were to succeed, such a transaction would contain no inputs and a single output.
8181

82-
If the witness is empty, the old serialization format should be used.
82+
If the witness is empty, the old serialization format must be used.
8383

8484
Currently, the only witness objects type supported are script witnesses which consist of a stack of byte arrays. It is encoded as a var_int item count followed by each item encoded as a var_int length followed by a string of bytes. Each txin has its own script witness. The number of script witnesses is not explicitly encoded as it is implied by txin_count. Empty script witnesses are encoded as a zero byte. The order of the script witnesses follows the same order as the associated txins.
8585

0 commit comments

Comments
 (0)