diff --git a/pkg/storegateway/bucket_chunk_reader.go b/pkg/storegateway/bucket_chunk_reader.go index 4a109b294a7..e4a240b66ce 100644 --- a/pkg/storegateway/bucket_chunk_reader.go +++ b/pkg/storegateway/bucket_chunk_reader.go @@ -147,7 +147,7 @@ func (r *bucketChunkReader) loadChunks(ctx context.Context, res []seriesChunks, return errors.Wrap(err, "parsing chunk length") } // We ignore the crc32 after the chunk data. - chunkEncDataLen := int(chunkDataLen) + chunks.ChunkEncodingSize + chunkEncDataLen := chunks.ChunkEncodingSize + int(chunkDataLen) cb := chunksPool.Get(chunkEncDataLen) fullyRead, err := io.ReadFull(reader, cb)