From 7994b5b22a598118cfc2fc1d010d8fdc6cfb9f37 Mon Sep 17 00:00:00 2001 From: Aliaksandr Valialkin Date: Sun, 26 May 2024 00:21:57 +0200 Subject: [PATCH] wip --- lib/logstorage/pipe_stats.go | 10 ++++++---- 1 file changed, 6 insertions(+), 4 deletions(-) diff --git a/lib/logstorage/pipe_stats.go b/lib/logstorage/pipe_stats.go index 77504dec2..90fdb0c73 100644 --- a/lib/logstorage/pipe_stats.go +++ b/lib/logstorage/pipe_stats.go @@ -133,16 +133,18 @@ func (ps *pipeStats) hasFilterInWithQuery() bool { func (ps *pipeStats) initFilterInValues(cache map[string][]string, getFieldValuesFunc getFieldValuesFunc) (pipe, error) { funcsNew := make([]pipeStatsFunc, len(ps.funcs)) - for i, f := range ps.funcs { + for i := range ps.funcs { + f := &ps.funcs[i] iffNew, err := f.iff.initFilterInValues(cache, getFieldValuesFunc) if err != nil { return nil, err } - f.iff = iffNew - funcsNew[i] = f + fNew := *f + fNew.iff = iffNew + funcsNew[i] = fNew } psNew := *ps - ps.funcs = funcsNew + psNew.funcs = funcsNew return &psNew, nil }