mirror of
https://github.com/izzy2lost/ppsspp.git
synced 2026-03-10 12:43:04 -07:00
Io: Prevent error on bad handle for DevType().
This commit is contained in:
@@ -561,6 +561,8 @@ int VirtualDiscFileSystem::Ioctl(u32 handle, u32 cmd, u32 indataPtr, u32 inlen,
|
||||
|
||||
PSPDevType VirtualDiscFileSystem::DevType(u32 handle) {
|
||||
EntryMap::iterator iter = entries.find(handle);
|
||||
if (iter == entries.end())
|
||||
return PSPDevType::FILE;
|
||||
PSPDevType type = iter->second.type == VFILETYPE_ISO ? PSPDevType::BLOCK : PSPDevType::FILE;
|
||||
if (iter->second.type == VFILETYPE_LBN)
|
||||
type |= PSPDevType::EMU_LBN;
|
||||
|
||||
Reference in New Issue
Block a user