summaryrefslogtreecommitdiff
path: root/Source/Core/DiscIO
diff options
context:
space:
mode:
authorAnthony <Helios747@users.noreply.github.com>2017-03-02 11:55:29 -0800
committerGitHub <noreply@github.com>2017-03-02 11:55:29 -0800
commit4e062d1bf6e1754325b5d55e6df65ee3d4769a9c (patch)
tree1848f63639ee46a169390484c7d8611b42988ccd /Source/Core/DiscIO
parent78e7f4aae3364d3299763395deee1103b5819dc6 (diff)
parentd97ae1054f3dddb840b93334a7cec69a7ba8f196 (diff)
Merge pull request #4981 from leoetlino/es-title-handling
IOS/ES: Proper active title tracking (+ neat accidental fixes)
Diffstat (limited to 'Source/Core/DiscIO')
-rw-r--r--Source/Core/DiscIO/Volume.h1
-rw-r--r--Source/Core/DiscIO/VolumeWiiCrypted.cpp7
-rw-r--r--Source/Core/DiscIO/VolumeWiiCrypted.h1
3 files changed, 9 insertions, 0 deletions
diff --git a/Source/Core/DiscIO/Volume.h b/Source/Core/DiscIO/Volume.h
index 1190565004..f3f530e5e4 100644
--- a/Source/Core/DiscIO/Volume.h
+++ b/Source/Core/DiscIO/Volume.h
@@ -37,6 +37,7 @@ public:
}
virtual bool GetTitleID(u64*) const { return false; }
+ virtual IOS::ES::TicketReader GetTicket() const { return {}; }
virtual IOS::ES::TMDReader GetTMD() const { return {}; }
virtual u64 PartitionOffsetToRawOffset(u64 offset) const { return offset; }
virtual std::string GetGameID() const = 0;
diff --git a/Source/Core/DiscIO/VolumeWiiCrypted.cpp b/Source/Core/DiscIO/VolumeWiiCrypted.cpp
index ef291fa237..71e50252db 100644
--- a/Source/Core/DiscIO/VolumeWiiCrypted.cpp
+++ b/Source/Core/DiscIO/VolumeWiiCrypted.cpp
@@ -114,6 +114,13 @@ bool CVolumeWiiCrypted::GetTitleID(u64* buffer) const
return true;
}
+IOS::ES::TicketReader CVolumeWiiCrypted::GetTicket() const
+{
+ std::vector<u8> buffer(0x2a4);
+ Read(m_VolumeOffset, buffer.size(), buffer.data(), false);
+ return IOS::ES::TicketReader{std::move(buffer)};
+}
+
IOS::ES::TMDReader CVolumeWiiCrypted::GetTMD() const
{
u32 tmd_size;
diff --git a/Source/Core/DiscIO/VolumeWiiCrypted.h b/Source/Core/DiscIO/VolumeWiiCrypted.h
index dfeb74ad66..d7e7c4bddb 100644
--- a/Source/Core/DiscIO/VolumeWiiCrypted.h
+++ b/Source/Core/DiscIO/VolumeWiiCrypted.h
@@ -33,6 +33,7 @@ public:
~CVolumeWiiCrypted();
bool Read(u64 _Offset, u64 _Length, u8* _pBuffer, bool decrypt) const override;
bool GetTitleID(u64* buffer) const override;
+ IOS::ES::TicketReader GetTicket() const override;
IOS::ES::TMDReader GetTMD() const override;
u64 PartitionOffsetToRawOffset(u64 offset) const override;
std::string GetGameID() const override;