mirror of
https://github.com/dolphin-emu/dolphin.git
synced 2025-07-24 14:49:42 -06:00
DiskIO: Clean up GetTMD() API.
This commit is contained in:
@ -3,6 +3,7 @@
|
||||
// Refer to the license.txt file included.
|
||||
|
||||
#include <cinttypes>
|
||||
#include <memory>
|
||||
|
||||
#include "Common/CommonTypes.h"
|
||||
#include "Common/Logging/LogManager.h"
|
||||
@ -113,11 +114,10 @@ bool CWII_IPC_HLE_Device_di::IOCtlV(u32 _CommandAddress)
|
||||
INFO_LOG(WII_IPC_DVD, "DVDLowOpenPartition: partition_offset 0x%016" PRIx64, partition_offset);
|
||||
|
||||
// Read TMD to the buffer
|
||||
u8 pTMD[0x800];
|
||||
u32 tmdSz;
|
||||
VolumeHandler::GetVolume()->GetTMD(pTMD, &tmdSz);
|
||||
Memory::CopyToEmu(CommandBuffer.PayloadBuffer[0].m_Address, pTMD, tmdSz);
|
||||
WII_IPC_HLE_Interface::ES_DIVerify(pTMD, tmdSz);
|
||||
u32 tmd_size;
|
||||
std::unique_ptr<u8[]> tmd_buf = VolumeHandler::GetVolume()->GetTMD(&tmd_size);
|
||||
Memory::CopyToEmu(CommandBuffer.PayloadBuffer[0].m_Address, tmd_buf.get(), tmd_size);
|
||||
WII_IPC_HLE_Interface::ES_DIVerify(tmd_buf.get(), tmd_size);
|
||||
|
||||
ReturnValue = 1;
|
||||
}
|
||||
|
Reference in New Issue
Block a user