From 1acb701e5c3c3faf7a55d754b6537f1413e39914 Mon Sep 17 00:00:00 2001 From: Ganesh Vernekar Date: Mon, 5 Jul 2021 21:51:35 +0530 Subject: [PATCH] Fix TSDB race while reading histograms Signed-off-by: Ganesh Vernekar --- tsdb/head.go | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/tsdb/head.go b/tsdb/head.go index 0787bb3d0..940d6af83 100644 --- a/tsdb/head.go +++ b/tsdb/head.go @@ -2889,7 +2889,7 @@ func (it *memSafeIterator) Next() bool { return false } it.i++ - if it.Iterator.ChunkEncoding() == chunkenc.EncSHS || it.total-it.i > 4 { + if it.total-it.i > 4 { return it.Iterator.Next() } return true