Compare commits

..

No commits in common. "c185f5058f78886afe4bee08b74d52d89a13b2e1" and "b44d364f0f039ea6f21368313020e746b5e454e2" have entirely different histories.

2 changed files with 4 additions and 8 deletions

View File

@ -255,15 +255,11 @@ func TestGenerateRunEncodeDecode(test *testing.T) {
[]byte { 0x00, 0x08, 0x63, 0x45, 0x12, 0x63, 0xCE },
[]byte { 0x00, 0x09, 0x67, 0x40, 0x74, 0x4E, 0x3D, 0x6F, 0xCD, 0x17, 0x75 },
[]byte { 0x00, 0x0A, 0x87, 'f', 'o', 'x', ' ', 'b', 'e', 'd' },
[]byte { 0x00, 0x0B, 0xC0, 0x04,
0x00, 0x07,
0x00, 0x06,
0x00, 0x05,
0x00, 0x04 },
[]byte { 0x00, 0x0C, 0xE0, 0x02, // ERR
[]byte { 0x00, 0x0B, 0xC4, 0x00, 0x07, 0x00, 0x06, 0x00, 0x05, 0x00, 0x04 },
[]byte { 0x00, 0x0C, 0xE1, 0x02,
0x00, 0x01, 0x20, 0x08,
0x00, 0x02, 0x67, 0x40, 0x11, 0x99, 0x99, 0x99, 0x99, 0x99, 0x9A },
[]byte { 0x00, 0x0D, 0xE0, 0x03, // ERR
[]byte { 0x00, 0x0D, 0xE1, 0x03,
0x00, 0x01, 0x63, 0x43, 0xF4, 0xC0, 0x00,
0x00, 0x02, 0x82, 'h', 'i',
0x00, 0x03, 0x21, 0x39, 0x92 },

View File

@ -78,6 +78,6 @@ func bufferLenTag(length int) Tag {
if length < int(CNLimit) {
return SBA.WithCN(length)
} else {
return LBA.WithCN(IntBytes(uint64(length)) - 1)
return LBA.WithCN(IntBytes(uint64(length)))
}
}