Skip to content

Commit

Permalink
Store: Fix panic too smaller buffer (thanos-io#7658)
Browse files Browse the repository at this point in the history
Co-authored-by: dominic.qi <dominic.qi@jaco.live>
Co-authored-by: Ben Ye <benye@amazon.com>
  • Loading branch information
3 people authored and jnyi committed Oct 16, 2024
1 parent 4d45694 commit be125cc
Showing 1 changed file with 1 addition and 0 deletions.
1 change: 1 addition & 0 deletions pkg/store/bucket.go
Original file line number Diff line number Diff line change
Expand Up @@ -3615,6 +3615,7 @@ func (r *bucketChunkReader) loadChunks(ctx context.Context, res []seriesEntry, a
bufPooled, err := r.block.chunkPool.Get(r.block.estimatedMaxChunkSize)
if err == nil {
buf = *bufPooled
defer r.block.chunkPool.Put(&buf)
} else {
buf = make([]byte, r.block.estimatedMaxChunkSize)
}
Expand Down

0 comments on commit be125cc

Please sign in to comment.