mirror of
https://git.ryujinx.app/ryubing/ryujinx.git
synced 2026-06-27 22:59:05 +00:00
Structural and Memory Safety Improvements, Analyzer Cleanup (ryubing/ryujinx!47)
See merge request ryubing/ryujinx!47
This commit is contained in:
@@ -93,9 +93,8 @@ namespace Ryujinx.HLE.HOS.Services.Nv
|
||||
private NvResult GetIoctlArgument(ServiceCtx context, NvIoctl ioctlCommand, out Span<byte> arguments)
|
||||
{
|
||||
(ulong inputDataPosition, ulong inputDataSize) = context.Request.GetBufferType0x21(0);
|
||||
#pragma warning disable IDE0059 // Remove unnecessary value assignment
|
||||
(ulong outputDataPosition, ulong outputDataSize) = context.Request.GetBufferType0x22(0);
|
||||
#pragma warning restore IDE0059
|
||||
|
||||
(_, ulong outputDataSize) = context.Request.GetBufferType0x22(0);
|
||||
|
||||
NvIoctl.Direction ioctlDirection = ioctlCommand.DirectionValue;
|
||||
uint ioctlSize = ioctlCommand.Size;
|
||||
@@ -307,9 +306,8 @@ namespace Ryujinx.HLE.HOS.Services.Nv
|
||||
// Initialize(u32 transfer_memory_size, handle<copy, process> current_process, handle<copy, transfer_memory> transfer_memory) -> u32 error_code
|
||||
public ResultCode Initialize(ServiceCtx context)
|
||||
{
|
||||
#pragma warning disable IDE0059 // Remove unnecessary value assignment
|
||||
long transferMemSize = context.RequestData.ReadInt64();
|
||||
#pragma warning restore IDE0059
|
||||
_ = context.RequestData.ReadInt64(); // transfer memory size
|
||||
|
||||
int transferMemHandle = context.Request.HandleDesc.ToCopy[1];
|
||||
|
||||
// TODO: When transfer memory will be implemented, this could be removed.
|
||||
@@ -431,9 +429,7 @@ namespace Ryujinx.HLE.HOS.Services.Nv
|
||||
// SetClientPID(u64, pid) -> u32 error_code
|
||||
public ResultCode SetClientPid(ServiceCtx context)
|
||||
{
|
||||
#pragma warning disable IDE0059 // Remove unnecessary value assignment
|
||||
long pid = context.RequestData.ReadInt64();
|
||||
#pragma warning restore IDE0059
|
||||
_ = context.RequestData.ReadInt64(); // pid
|
||||
|
||||
context.ResponseData.Write(0);
|
||||
|
||||
|
||||
Reference in New Issue
Block a user