VolumeWii: Change the format of partition maps

Having a separate map for each type of data is a bit unnecessary.
This commit is contained in:
JosJuice
2017-07-04 16:08:12 +02:00
parent e0b94b55b8
commit 333b6d99d2
2 changed files with 24 additions and 21 deletions

View File

@ -64,11 +64,16 @@ public:
static constexpr unsigned int BLOCK_TOTAL_SIZE = BLOCK_HEADER_SIZE + BLOCK_DATA_SIZE;
private:
struct PartitionDetails
{
std::unique_ptr<mbedtls_aes_context> key;
IOS::ES::TicketReader ticket;
IOS::ES::TMDReader tmd;
u32 type;
};
std::unique_ptr<BlobReader> m_pReader;
std::map<Partition, u32> m_partition_types;
std::map<Partition, std::unique_ptr<mbedtls_aes_context>> m_partition_keys;
std::map<Partition, IOS::ES::TicketReader> m_partition_tickets;
std::map<Partition, IOS::ES::TMDReader> m_partition_tmds;
std::map<Partition, PartitionDetails> m_partitions;
Partition m_game_partition;
mutable u64 m_last_decrypted_block;