codec/mjpeg/utils.go: using BigEndian.Uint16 in get16

This commit is contained in:
Saxon 2019-12-23 13:59:27 +10:30
parent 657ed2f277
commit 7c8ba0ae4b
1 changed files with 1 additions and 1 deletions

View File

@ -95,7 +95,7 @@ func (b *byteStream) get8() int {
} }
func (b *byteStream) get16() int { func (b *byteStream) get16() int {
v := int(b.bytes[b.i])<<8 | int(b.bytes[b.i+1]) v := int(binary.BigEndian.Uint16(b.bytes[b.i:]))
b.i += 2 b.i += 2
return v return v
} }