Git: BranchModel: Guard against detaching QList

Change-Id: Ia55d2dd5c4c5a0320704f33688663e2f8954a4ff
Reviewed-by: Eike Ziller <eike.ziller@qt.io>
Reviewed-by: Orgad Shaneh <orgads@gmail.com>
This commit is contained in:
Andre Hartmann
2025-03-19 09:17:23 +01:00
committed by André Hartmann
parent 4787d0d166
commit c95ab42eef

View File

@@ -967,7 +967,7 @@ void BranchModel::Private::updateAllUpstreamStatus(BranchNode *node)
q->updateUpstreamStatus(node);
return;
}
for (BranchNode *child : node->children)
for (BranchNode *child : std::as_const(node->children))
updateAllUpstreamStatus(child);
}