diff --git a/streamingvisitors/src/vespa/vsm/searcher/utf8flexiblestringfieldsearcher.cpp b/streamingvisitors/src/vespa/vsm/searcher/utf8flexiblestringfieldsearcher.cpp index 5f626ccb9620..4a8e7a434756 100644 --- a/streamingvisitors/src/vespa/vsm/searcher/utf8flexiblestringfieldsearcher.cpp +++ b/streamingvisitors/src/vespa/vsm/searcher/utf8flexiblestringfieldsearcher.cpp @@ -2,6 +2,7 @@ #include "utf8flexiblestringfieldsearcher.h" #include #include +#include #include #include @@ -24,7 +25,7 @@ UTF8FlexibleStringFieldSearcher::matchTerms(const FieldRef & f, const size_t min (void) mintsz; size_t words = 0; for (auto qt : _qtl) { - words = matchTerm(f, *qt); + words = std::max(words, matchTerm(f, *qt)); } return words; }