From 756a6f82617d0990bb02b3f2b00973c67d9d25f9 Mon Sep 17 00:00:00 2001 From: Zsolt Felfoldi Date: Tue, 15 Apr 2025 00:14:47 +0200 Subject: [PATCH] core/filtermaps: safe row access in matcher backend --- core/filtermaps/matcher_backend.go | 3 +++ 1 file changed, 3 insertions(+) diff --git a/core/filtermaps/matcher_backend.go b/core/filtermaps/matcher_backend.go index 01bae7bb22..335ac84551 100644 --- a/core/filtermaps/matcher_backend.go +++ b/core/filtermaps/matcher_backend.go @@ -75,6 +75,9 @@ func (fm *FilterMapsMatcherBackend) Close() { // on write. // GetFilterMapRow implements MatcherBackend. func (fm *FilterMapsMatcherBackend) GetFilterMapRow(ctx context.Context, mapIndex, rowIndex uint32, baseLayerOnly bool) (FilterRow, error) { + fm.f.indexLock.RLock() + defer fm.f.indexLock.RUnlock() + return fm.f.getFilterMapRow(mapIndex, rowIndex, baseLayerOnly) }