mirror of
https://github.com/RetroDECK/ES-DE.git
synced 2025-01-31 04:25:40 +00:00
Fixed an issue where repopulating an empty 'recent' auto collection could crash the application.
This commit is contained in:
parent
fe4e94a827
commit
71e40f4eb4
|
@ -1105,7 +1105,7 @@ void CollectionSystemsManager::populateAutoCollection(CollectionSystemData* sysD
|
|||
// For the 'recent' collection we need to populate the gamelist once more as the
|
||||
// collection was trimmed down to 50 items. If we don't do this, the game count will
|
||||
// not be correct as it would include all the games prior to trimming.
|
||||
if (rootFolder->getName() == "recent") {
|
||||
if (rootFolder->getName() == "recent" && !rootFolder->getChildrenRecursive().empty()) {
|
||||
// The following is needed to avoid a crash when repopulating the system as the previous
|
||||
// cursor pointer may point to a random memory address.
|
||||
auto recentGamelist = ViewController::get()->getGameListView(rootFolder->getSystem()).get();
|
||||
|
|
Loading…
Reference in a new issue