Commit b50577a0 authored by Waqar Ahmed's avatar Waqar Ahmed Committed by Christoph Cullmann
Browse files

Fix infinite recursion in project filter model

BUG: 443026
parent ba72e0ca
Pipeline #84543 passed with stage
in 6 minutes
......@@ -35,8 +35,17 @@ protected:
return true;
// If index is invalid(root index), return true
// The rowCount(invalidIndex) can be same as model->rowCount() and when
// we are recursively filtering, we get stuck on this index i.e.,
// trying to check its children again and again recursively.
auto index = sourceModel()->index(sourceRow, 0, sourceParent);
if (!index.isValid()) {
return true;
int score = 0; // unused intentionally
QString file = sourceModel()->index(sourceRow, 0, sourceParent).data().toString();
QString file =;
return kfts::fuzzy_match(m_pattern, file, score);
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment