IOS/ES: Implement ES_Export* ioctlvs

This should allow channels to be copied to the SD properly.
This commit is contained in:
Léo Lam
2017-02-25 01:03:22 +01:00
parent 345d252ef3
commit 6327a29847
4 changed files with 218 additions and 6 deletions

View File

@ -161,6 +161,14 @@ bool CNANDContentLoader::IsValid() const
return m_Valid && m_tmd.IsValid();
}
const SNANDContent* CNANDContentLoader::GetContentByID(u32 id) const
{
const auto iterator = std::find_if(m_Content.begin(), m_Content.end(), [id](const auto& content) {
return content.m_metadata.id == id;
});
return iterator != m_Content.end() ? &*iterator : nullptr;
}
const SNANDContent* CNANDContentLoader::GetContentByIndex(int index) const
{
for (auto& Content : m_Content)