Propagate elf loading failure up.

Also fix mistake in error message.
This commit is contained in:
Scott Mansell 2014-11-02 20:34:59 +13:00
parent b7d4ff679a
commit 5c34766809
3 changed files with 5 additions and 3 deletions

View File

@ -349,7 +349,8 @@ bool CBoot::BootUp()
EmulatedBS2_GC(true); EmulatedBS2_GC(true);
Load_FST(_StartupPara.bWii); Load_FST(_StartupPara.bWii);
Boot_ELF(_StartupPara.m_strFilename); if(!Boot_ELF(_StartupPara.m_strFilename))
return false;
UpdateDebugger_MapLoaded(); UpdateDebugger_MapLoaded();
Dolphin_Debugger::AddAutoBreakpoints(); Dolphin_Debugger::AddAutoBreakpoints();

View File

@ -64,7 +64,8 @@ bool CBoot::Boot_ELF(const std::string& filename)
// Load ELF into GameCube Memory // Load ELF into GameCube Memory
ElfReader reader(elf.get()); ElfReader reader(elf.get());
reader.LoadIntoMemory(); if(!reader.LoadIntoMemory())
return false;
if (!reader.LoadSymbols()) if (!reader.LoadSymbols())
{ {

View File

@ -104,7 +104,7 @@ bool ElfReader::LoadIntoMemory()
if (bRelocate) if (bRelocate)
{ {
PanicAlert("Error: Dolphin doesn't know to load a relocatable elf."); PanicAlert("Error: Dolphin doesn't know how to load a relocatable elf.");
return false; return false;
} }