Skip to content
Snippets Groups Projects
Commit 568bcbc2 authored by Lioncash's avatar Lioncash
Browse files

kernel/handle_table: Restrict handle table size to 1024 entries

The previous handle table size is a holdover from Citra. The actual
handle table construct on Horizon only allows for a maximum of 1024
entries.
parent f5ce7179
No related branches found
No related tags found
No related merge requests found
...@@ -90,11 +90,8 @@ public: ...@@ -90,11 +90,8 @@ public:
void Clear(); void Clear();
private: private:
/** /// This is the maximum limit of handles allowed per process in Horizon
* This is the maximum limit of handles allowed per process in CTR-OS. It can be further static constexpr std::size_t MAX_COUNT = 1024;
* reduced by ExHeader values, but this is not emulated here.
*/
static const std::size_t MAX_COUNT = 4096;
static u16 GetSlot(Handle handle) { static u16 GetSlot(Handle handle) {
return handle >> 15; return handle >> 15;
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment