Ninjastic
Home
Search
Users
Boards
Addresses
Ctrl + K
Toggle theme
Open menu
Post
Edited versions
Quotes to this post
Post
9560967
Topic
857729
Board
Development & Technical Discussion
Re: Transaction id hashing and var_ints
by
harding
on
16/11/2014, 15:17:32 UTC
It looks to me like CompactSize requires the smallest possible encoding. See:
https://github.com/bitcoin/bitcoin/blob/master/src/serialize.h#L218
It also looks like there are some tests to ensure non-canonical compatSize uints are forbidden in the test cases. See:
https://github.com/bitcoin/bitcoin/blob/master/src/test/serialize_tests.cpp#L81