mirror of
https://github.com/prometheus/prometheus.git
synced 2025-01-29 22:51:36 -08:00
bugfix: only bump numRead when all fields are successfully read
Signed-off-by: Dieter Plaetinck <dieter@grafana.com>
This commit is contained in:
parent
98f86d671a
commit
dc6b068c67
|
@ -632,6 +632,7 @@ func (it *histoIterator) Next() bool {
|
||||||
it.negbuckets[i] = it.negbuckets[i] + delta
|
it.negbuckets[i] = it.negbuckets[i] + delta
|
||||||
}
|
}
|
||||||
|
|
||||||
|
it.numRead++
|
||||||
return true
|
return true
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -684,6 +685,7 @@ func (it *histoIterator) Next() bool {
|
||||||
it.negbuckets[i] = it.negbuckets[i] + it.negbucketsDelta[i]
|
it.negbuckets[i] = it.negbuckets[i] + it.negbucketsDelta[i]
|
||||||
}
|
}
|
||||||
|
|
||||||
|
it.numRead++
|
||||||
return true
|
return true
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -752,6 +754,5 @@ func (it *histoIterator) readSum() bool {
|
||||||
it.sum = math.Float64frombits(vbits)
|
it.sum = math.Float64frombits(vbits)
|
||||||
}
|
}
|
||||||
|
|
||||||
it.numRead++
|
|
||||||
return true
|
return true
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in a new issue