Compare commits

...

2 Commits
1.1.4 ... 1.1.6

Author SHA1 Message Date
b2ebbe8b22 amadeus: Fix possible device sink input out of bound (#3032)
This fix an out of bound when indexing inputs for games that uses
unsupported values (8 here)

Close #2724.
2022-01-23 23:36:31 +01:00
4910b214f5 Set _vibrationPermitted to True by default (#2985)
Co-authored-by: SpookyBee123 <82302189+SpookyBee123@users.noreply.github.com>
2022-01-23 12:24:55 +01:00
2 changed files with 3 additions and 3 deletions

View File

@ -52,7 +52,7 @@ namespace Ryujinx.Audio.Renderer.Dsp.Command
InputCount = sink.Parameter.InputCount; InputCount = sink.Parameter.InputCount;
InputBufferIndices = new ushort[InputCount]; InputBufferIndices = new ushort[InputCount];
for (int i = 0; i < InputCount; i++) for (int i = 0; i < Math.Min(InputCount, Constants.ChannelCountMax); i++)
{ {
InputBufferIndices[i] = (ushort)(bufferOffset + sink.Parameter.Input[i]); InputBufferIndices[i] = (ushort)(bufferOffset + sink.Parameter.Input[i]);
} }

View File

@ -55,6 +55,8 @@ namespace Ryujinx.HLE.HOS.Services.Hid
// TODO: signal event at right place // TODO: signal event at right place
_xpadIdEvent.ReadableEvent.Signal(); _xpadIdEvent.ReadableEvent.Signal();
_vibrationPermitted = true;
} }
[CommandHipc(0)] [CommandHipc(0)]
@ -1141,8 +1143,6 @@ namespace Ryujinx.HLE.HOS.Services.Hid
{ {
context.ResponseData.Write(_vibrationPermitted); context.ResponseData.Write(_vibrationPermitted);
Logger.Stub?.PrintStub(LogClass.ServiceHid, new { _vibrationPermitted });
return ResultCode.Success; return ResultCode.Success;
} }