mirror of
https://github.com/scylladb/scylladb.git
synced 2026-04-25 02:50:33 +00:00
The uncompression code reads the compressed chunks containing the bytes pos through pos + len - 1. This, however, is not correct when len==0, and pos + len - 1 may even be -1, causing an out-of-range exception when calling locate() to find the chunks containing this byte position. So we need to treat len==0 specially, and in this case we don't read anything, and don't need to locate() the chunks to read. Refs #1039. Signed-off-by: Nadav Har'El <nyh@scylladb.com> Message-Id: <1458135987-10200-1-git-send-email-nyh@scylladb.com>