Boot: Check TMD validity before reading from TMD
Otherwise Dolphin crashes when trying to boot a Wii game with an invalid TMD.
This commit is contained in:
parent
9885a2bb28
commit
fdd197475b
|
@ -343,6 +343,9 @@ bool CBoot::EmulatedBS2_Wii(const DiscIO::Volume* volume)
|
|||
const DiscIO::Partition partition = volume->GetGamePartition();
|
||||
const IOS::ES::TMDReader tmd = volume->GetTMD(partition);
|
||||
|
||||
if (!tmd.IsValid())
|
||||
return false;
|
||||
|
||||
if (!SetupWiiMemory(volume, tmd.GetIOSId()))
|
||||
return false;
|
||||
|
||||
|
|
Loading…
Reference in New Issue