mirror of
https://github.com/dolphin-emu/dolphin.git
synced 2025-07-23 14:19:46 -06:00
Remove all tab/space mismatches from the Core project. For anyone working on a branch that heavily involves the core, I am so sorry.
- Also killed off some trailing spaces/tabs. - Updated the license header to be consistent with the rest of the project (All projects are now done moving over to this) - Also, killed some dangling else's (where appropriate) Now all the tab fixing is done. No more of this crap should be needed to be pushed. Rejoice!
This commit is contained in:
@ -46,7 +46,7 @@ bool ShowSound(std::string FileName)
|
||||
SplitPath(FileName, NULL, NULL, &Ending);
|
||||
std::transform(Ending.begin(),Ending.end(),Ending.begin(),::tolower);
|
||||
|
||||
if (
|
||||
if (
|
||||
(Ending == ".adp") // 1080 Avalanche, Crash Bandicoot, etc
|
||||
|| (Ending == ".afc") // Zelda WW
|
||||
|| (Ending == ".ast") // Zelda TP, Mario Kart
|
||||
@ -76,6 +76,7 @@ void ReadGC(std::string FileName)
|
||||
delete pFileSystem;
|
||||
pFileSystem = NULL;
|
||||
}
|
||||
|
||||
// GCFiles' pointers are no longer valid after pFileSystem is cleared
|
||||
GCFiles.clear();
|
||||
OpenISO = DiscIO::CreateVolumeFromFilename(FileName);
|
||||
@ -99,7 +100,9 @@ void CheckFile(std::string File, u64 Size)
|
||||
if (CurrentFile == File)
|
||||
return;
|
||||
|
||||
if (Size > 0) Size = (Size / 1000);
|
||||
if (Size > 0)
|
||||
Size = (Size / 1000);
|
||||
|
||||
std::string Str = StringFromFormat("%s kB %s", ThousandSeparate(Size, 7).c_str(), File.c_str());
|
||||
if (ShowSound(File))
|
||||
{
|
||||
@ -119,10 +122,16 @@ void CheckFile(std::string File, u64 Size)
|
||||
void FindFilename(u64 offset)
|
||||
{
|
||||
// Don't do anything if a game is not running
|
||||
if (Core::GetState() != Core::CORE_RUN) return;
|
||||
if (Core::GetState() != Core::CORE_RUN)
|
||||
return;
|
||||
|
||||
// Or if the log is unselected
|
||||
if (!LogManager::GetInstance()->IsEnabled(LogTypes::FILEMON)) return;
|
||||
if (!FileAccess) return;
|
||||
if (!LogManager::GetInstance()->IsEnabled(LogTypes::FILEMON))
|
||||
return;
|
||||
|
||||
// Or if we don't have file access
|
||||
if (!FileAccess)
|
||||
return;
|
||||
|
||||
if (!pFileSystem || ISOFile != SConfig::GetInstance().m_LastFilename)
|
||||
{
|
||||
|
@ -260,17 +260,18 @@ bool CNANDContentLoader::Initialize(const std::string& _rName)
|
||||
rContent.m_Size= (u32)Common::swap64(pTMD + 0x01ec + 0x24*i);
|
||||
memcpy(rContent.m_SHA1Hash, pTMD + 0x01f4 + 0x24*i, 20);
|
||||
memcpy(rContent.m_Header, pTMD + 0x01e4 + 0x24*i, 36);
|
||||
|
||||
if (m_isWAD)
|
||||
{
|
||||
u32 RoundedSize = ROUND_UP(rContent.m_Size, 0x40);
|
||||
rContent.m_pData = new u8[RoundedSize];
|
||||
u32 RoundedSize = ROUND_UP(rContent.m_Size, 0x40);
|
||||
rContent.m_pData = new u8[RoundedSize];
|
||||
|
||||
memset(IV, 0, sizeof IV);
|
||||
memcpy(IV, pTMD + 0x01e8 + 0x24*i, 2);
|
||||
AESDecode(DecryptTitleKey, IV, pDataApp, RoundedSize, rContent.m_pData);
|
||||
memset(IV, 0, sizeof IV);
|
||||
memcpy(IV, pTMD + 0x01e8 + 0x24*i, 2);
|
||||
AESDecode(DecryptTitleKey, IV, pDataApp, RoundedSize, rContent.m_pData);
|
||||
|
||||
pDataApp += RoundedSize;
|
||||
continue;
|
||||
pDataApp += RoundedSize;
|
||||
continue;
|
||||
}
|
||||
|
||||
rContent.m_pData = NULL;
|
||||
@ -282,7 +283,9 @@ bool CNANDContentLoader::Initialize(const std::string& _rName)
|
||||
strcpy(szFilename, Filename.c_str());
|
||||
}
|
||||
else
|
||||
{
|
||||
sprintf(szFilename, "%s/%08x.app", m_Path.c_str(), rContent.m_ContentID);
|
||||
}
|
||||
|
||||
INFO_LOG(DISCIO, "NANDContentLoader: load %s", szFilename);
|
||||
|
||||
|
@ -62,7 +62,7 @@ public:
|
||||
virtual const u8* GetTMDHeader() const = 0;
|
||||
virtual u32 GetTIKSize() const = 0;
|
||||
virtual const u8* GetTIK() const = 0;
|
||||
virtual const std::vector<SNANDContent>& GetContent() const = 0;
|
||||
virtual const std::vector<SNANDContent>& GetContent() const = 0;
|
||||
virtual u16 GetTitleVersion() const = 0;
|
||||
virtual u16 GetNumEntries() const = 0;
|
||||
virtual DiscIO::IVolume::ECountry GetCountry() const = 0;
|
||||
|
@ -69,7 +69,7 @@ IVolume::ECountry CountrySwitch(u8 CountryCode)
|
||||
case 'T': // Korea with English language
|
||||
case 'Q': // Korea with Japanese language
|
||||
return IVolume::COUNTRY_KOREA;
|
||||
break;
|
||||
break;
|
||||
|
||||
case 'O':
|
||||
return IVolume::COUNTRY_SDK;
|
||||
|
@ -469,7 +469,7 @@ void CVolumeDirectory::WriteEntry(const File::FSTEntry& entry, u32& fstOffset, u
|
||||
if(entry.isDirectory)
|
||||
{
|
||||
u32 myOffset = fstOffset;
|
||||
u32 myEntryNum = myOffset / ENTRY_SIZE;
|
||||
u32 myEntryNum = myOffset / ENTRY_SIZE;
|
||||
WriteEntryData(fstOffset, DIRECTORY_ENTRY, nameOffset, parentEntryNum, (u32)(myEntryNum + entry.size + 1));
|
||||
WriteEntryName(nameOffset, entry.virtualName);
|
||||
|
||||
|
@ -112,10 +112,11 @@ bool WiiWAD::ParseWAD(DiscIO::IBlobReader& _rReader)
|
||||
m_TMDSize = ReaderBig.Read32(0x14);
|
||||
m_DataAppSize = ReaderBig.Read32(0x18);
|
||||
m_FooterSize = ReaderBig.Read32(0x1C);
|
||||
|
||||
#if MAX_LOGLEVEL >= DEBUG_LEVEL
|
||||
_dbg_assert_msg_(BOOT, Reserved==0x00, "WiiWAD: Reserved must be 0x00");
|
||||
_dbg_assert_msg_(BOOT, Reserved==0x00, "WiiWAD: Reserved must be 0x00");
|
||||
#else
|
||||
(void)Reserved;
|
||||
(void)Reserved;
|
||||
#endif
|
||||
|
||||
u32 Offset = 0x40;
|
||||
|
Reference in New Issue
Block a user