HLE: fix unreachable code warning

This commit is contained in:
Shawn Hoffman 2017-06-07 04:18:23 -07:00
parent f730b775b6
commit 90f863a7a3
1 changed files with 3 additions and 1 deletions

View File

@ -247,8 +247,10 @@ u32 UnPatch(const std::string& patch_name)
return addr; return addr;
} }
for (const auto& symbol : g_symbolDB.GetSymbolsFromName(patch_name)) const auto& symbols = g_symbolDB.GetSymbolsFromName(patch_name);
if (symbols.size())
{ {
const auto& symbol = symbols[0];
for (u32 addr = symbol->address; addr < symbol->address + symbol->size; addr += 4) for (u32 addr = symbol->address; addr < symbol->address + symbol->size; addr += 4)
{ {
s_original_instructions.erase(addr); s_original_instructions.erase(addr);