Fix size packing/unpacking for EXT 8/16/32

For EXT 8/16/32, the "size" field incremented by 1 to account for the type byte,
but according to the specification, the size should only consider the data field.

This commit also fixes interoperability with python and ruby implementations