mirror of
https://github.com/Atmosphere-NX/Atmosphere.git
synced 2024-12-23 02:42:09 +00:00
lr: update capacity constants to reflect 12.0.0 changes
This commit is contained in:
parent
4db485083b
commit
a809e23320
1 changed files with 12 additions and 1 deletions
|
@ -25,8 +25,19 @@ namespace ams::lr {
|
|||
private:
|
||||
/* Storage for RegisteredData entries by data id. */
|
||||
RegisteredStorages<ncm::DataId, 0x800> m_registered_storages;
|
||||
private:
|
||||
static ALWAYS_INLINE size_t GetStorageCapacity() {
|
||||
const auto version = hos::GetVersion();
|
||||
if (version >= hos::Version_12_0_0) {
|
||||
return 0x8;
|
||||
} else if (version >= hos::Version_9_0_0) {
|
||||
return 0x2;
|
||||
} else {
|
||||
return 0x800;
|
||||
}
|
||||
}
|
||||
public:
|
||||
AddOnContentLocationResolverImpl() : m_registered_storages(hos::GetVersion() < hos::Version_9_0_0 ? 0x800 : 0x2) { /* ... */ }
|
||||
AddOnContentLocationResolverImpl() : m_registered_storages(GetStorageCapacity()) { /* ... */ }
|
||||
|
||||
/* Actual commands. */
|
||||
Result ResolveAddOnContentPath(sf::Out<Path> out, ncm::DataId id);
|
||||
|
|
Loading…
Reference in a new issue