mirror of
https://github.com/dolphin-emu/dolphin.git
synced 2024-11-14 13:27:45 -07:00
Merge pull request #5585 from JosJuice/volumedirectory-minor-fixes
VolumeDirectory: Minor fixes
This commit is contained in:
commit
0a69331371
@ -333,7 +333,7 @@ bool VolumeDirectory::SetApploader(const std::string& apploader)
|
||||
{
|
||||
m_apploader.resize(0x20);
|
||||
// Make sure BS2 HLE doesn't try to run the apploader
|
||||
*(u32*)&m_apploader[0x10] = (u32)-1;
|
||||
Write32(static_cast<u32>(-1), 0x10, &m_apploader);
|
||||
return false;
|
||||
}
|
||||
}
|
||||
@ -372,7 +372,7 @@ void VolumeDirectory::BuildFST()
|
||||
if (m_fst_address == 0)
|
||||
m_fst_address = APPLOADER_ADDRESS + 0x2000;
|
||||
|
||||
// 4 byte aligned start of data on disk
|
||||
// 32 KiB aligned start of data on disk
|
||||
m_data_start_address = Common::AlignUp(m_fst_address + m_fst_data.size(), 0x8000ull);
|
||||
u64 current_data_address = m_data_start_address;
|
||||
|
||||
@ -494,7 +494,7 @@ void VolumeDirectory::WriteDirectory(const File::FSTEntry& parent_entry, u32* fs
|
||||
_dbg_assert_(DVDINTERFACE, m_virtual_disk.find(*data_offset) == m_virtual_disk.end());
|
||||
m_virtual_disk.emplace(*data_offset, entry.physicalName);
|
||||
|
||||
// 4 byte aligned
|
||||
// 32 KiB aligned - many games are fine with less alignment, but not all
|
||||
*data_offset = Common::AlignUp(*data_offset + std::max<u64>(entry.size, 1ull), 0x8000ull);
|
||||
}
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user