mirror of
https://github.com/Ryubing/Ryujinx.git
synced 2025-11-29 13:22:23 -05:00
Move WriteBytes to AMemory, implement it with a Marshal copy like ReadBytes, fix regression on address range checking
This commit is contained in:
@@ -1,4 +1,3 @@
|
||||
using ChocolArm64.Memory;
|
||||
using Ryujinx.Core.OsHle.Ipc;
|
||||
using Ryujinx.Core.OsHle.Utilities;
|
||||
using System.Collections.Generic;
|
||||
@@ -131,7 +130,7 @@ namespace Ryujinx.Core.OsHle.Services.Bsd
|
||||
|
||||
//Logging.Debug("Received Buffer:" + Environment.NewLine + Logging.HexDump(ReceivedBuffer));
|
||||
|
||||
AMemoryHelper.WriteBytes(Context.Memory, Context.Request.ReceiveBuff[0].Position, ReceivedBuffer);
|
||||
Context.Memory.WriteBytes(Context.Request.ReceiveBuff[0].Position, ReceivedBuffer);
|
||||
|
||||
Context.ResponseData.Write(BytesRead);
|
||||
Context.ResponseData.Write(0);
|
||||
@@ -266,7 +265,7 @@ namespace Ryujinx.Core.OsHle.Services.Bsd
|
||||
|
||||
Writer.Write(IpAddress);
|
||||
|
||||
AMemoryHelper.WriteBytes(Context.Memory, AddrBufferPtr, MS.ToArray());
|
||||
Context.Memory.WriteBytes(AddrBufferPtr, MS.ToArray());
|
||||
|
||||
Context.ResponseData.Write(Sockets.Count - 1);
|
||||
Context.ResponseData.Write(0);
|
||||
|
||||
Reference in New Issue
Block a user