Fix crash when viewing models in GammaRay

In DataManger::getFeed, it doesn't check if the index is less than 0.
This commit is contained in:
Joshua Goins 2025-01-25 20:01:40 -05:00 committed by Bart De Vries
parent 8d3cafbb04
commit 93308f91e0

View File

@ -133,7 +133,7 @@ DataManager::DataManager()
Feed *DataManager::getFeed(const int index) const
{
if (index < m_feedmap.size()) {
if (index >= 0 && index < m_feedmap.size()) {
return getFeed(m_feedmap[index]);
}
return nullptr;