mirror of
https://github.com/hrydgard/ppsspp.git
synced 2024-11-27 15:30:35 +00:00
Don't crash if the cheat file is inaccessible.
This commit is contained in:
parent
24ead296f1
commit
bbaacab315
@ -219,6 +219,9 @@ std::vector<std::string> CWCheatEngine::GetCodesList() { //Reads the entire chea
|
||||
std::string line;
|
||||
std::vector<std::string> codesList; // Read from INI here
|
||||
std::ifstream list(activeCheatFile.c_str());
|
||||
if (!list) {
|
||||
return codesList;
|
||||
}
|
||||
for (int i = 0; !list.eof(); i ++) {
|
||||
getline(list, line, '\n');
|
||||
if (line.length() > 3 && line.substr(0,1) == "_"){
|
||||
|
Loading…
Reference in New Issue
Block a user