diff options
author | bunnei <bunneidev@gmail.com> | 2016-06-02 03:19:16 +0200 |
---|---|---|
committer | bunnei <bunneidev@gmail.com> | 2016-06-02 03:19:16 +0200 |
commit | 63557e3fc1ad44a3178ebb9c9222636e2555e5d1 (patch) | |
tree | b779fade21bc2cddf1424d4808ee237fbd9d3ee9 /src | |
parent | Merge pull request #1812 from JayFoxRox/refactor-shader (diff) | |
parent | AddFstEntriesToGameList - prevent loading a directory (diff) | |
download | yuzu-63557e3fc1ad44a3178ebb9c9222636e2555e5d1.tar yuzu-63557e3fc1ad44a3178ebb9c9222636e2555e5d1.tar.gz yuzu-63557e3fc1ad44a3178ebb9c9222636e2555e5d1.tar.bz2 yuzu-63557e3fc1ad44a3178ebb9c9222636e2555e5d1.tar.lz yuzu-63557e3fc1ad44a3178ebb9c9222636e2555e5d1.tar.xz yuzu-63557e3fc1ad44a3178ebb9c9222636e2555e5d1.tar.zst yuzu-63557e3fc1ad44a3178ebb9c9222636e2555e5d1.zip |
Diffstat (limited to 'src')
-rw-r--r-- | src/citra_qt/game_list.cpp | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/src/citra_qt/game_list.cpp b/src/citra_qt/game_list.cpp index 49cb98e70..15484fae3 100644 --- a/src/citra_qt/game_list.cpp +++ b/src/citra_qt/game_list.cpp @@ -130,9 +130,7 @@ void GameListWorker::AddFstEntriesToGameList(const std::string& dir_path, unsign if (stop_processing) return false; // Breaks the callback loop. - if (recursion > 0 && FileUtil::IsDirectory(physical_name)) { - AddFstEntriesToGameList(physical_name, recursion - 1); - } else { + if (!FileUtil::IsDirectory(physical_name)) { std::unique_ptr<Loader::AppLoader> loader = Loader::GetLoader(physical_name); if (!loader) return true; @@ -145,6 +143,8 @@ void GameListWorker::AddFstEntriesToGameList(const std::string& dir_path, unsign new GameListItem(QString::fromStdString(Loader::GetFileTypeString(loader->GetFileType()))), new GameListItemSize(FileUtil::GetSize(physical_name)), }); + } else if (recursion > 0) { + AddFstEntriesToGameList(physical_name, recursion - 1); } return true; |