diff options
Diffstat (limited to 'src/core/loader')
-rw-r--r-- | src/core/loader/3dsx.cpp | 2 | ||||
-rw-r--r-- | src/core/loader/loader.cpp | 18 |
2 files changed, 10 insertions, 10 deletions
diff --git a/src/core/loader/3dsx.cpp b/src/core/loader/3dsx.cpp index d043fa9bd..530837d08 100644 --- a/src/core/loader/3dsx.cpp +++ b/src/core/loader/3dsx.cpp @@ -191,7 +191,7 @@ static THREEDSX_Error Load3DSXFile(FileUtil::IOFile& file, u32 base_addr, Shared *pos = (addr); break; case 1: - *pos = (addr - in_addr); + *pos = static_cast<u32>(addr - in_addr); break; default: break; //this should never happen diff --git a/src/core/loader/loader.cpp b/src/core/loader/loader.cpp index 9ef2f8900..f5b349a77 100644 --- a/src/core/loader/loader.cpp +++ b/src/core/loader/loader.cpp @@ -56,18 +56,18 @@ static FileType IdentifyFile(FileUtil::IOFile& file) { static FileType GuessFromExtension(const std::string& extension_) { std::string extension = Common::ToLower(extension_); - if (extension == ".elf") + if (extension == ".elf" || extension == ".axf") return FileType::ELF; - else if (extension == ".axf") - return FileType::ELF; - else if (extension == ".cxi") - return FileType::CXI; - else if (extension == ".cci") - return FileType::CCI; - else if (extension == ".3ds") + + if (extension == ".cci" || extension == ".3ds") return FileType::CCI; - else if (extension == ".3dsx") + + if (extension == ".cxi") + return FileType::CXI; + + if (extension == ".3dsx") return FileType::THREEDSX; + return FileType::Unknown; } |