mirror of
https://git.743378673.xyz/MeloNX/MeloNX.git
synced 2025-07-22 14:47:10 +02:00
[Hotfix] hid: Prevent out of bounds array access (#5547)
* hid: Prevent out of bounds array access * Cast player to uint * Replace lambda function with local function
This commit is contained in:
parent
5e9678c8fa
commit
fe15c77d30
2 changed files with 22 additions and 16 deletions
|
@ -70,6 +70,11 @@ namespace Ryujinx.HLE.HOS.Services.Hid
|
|||
|
||||
internal void SetSupportedPlayer(PlayerIndex player, bool supported = true)
|
||||
{
|
||||
if ((uint)player >= _supportedPlayers.Length)
|
||||
{
|
||||
return;
|
||||
}
|
||||
|
||||
_supportedPlayers[(int)player] = supported;
|
||||
}
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue