mirror of
https://github.com/prometheus/prometheus.git
synced 2025-01-12 06:17:27 -08:00
promql/parser: Cleanup generatedParserResult accross reuse
Reusing the same generatedParserResult ends up in strange panics: See #7131 and #7127. Signed-off-by: Julien Pivotto <roidelapluie@inuits.eu>
This commit is contained in:
parent
386aea7774
commit
1f6f8e60ee
|
@ -168,6 +168,7 @@ func newParser(input string) *parser {
|
|||
|
||||
p.injecting = false
|
||||
p.parseErrors = nil
|
||||
p.generatedParserResult = nil
|
||||
|
||||
// Clear lexer struct before reusing.
|
||||
p.lex = Lexer{
|
||||
|
|
Loading…
Reference in a new issue