MemoryManagement: Change return types for Commit/Decommit to void (#5325)

* Replace return type with void for Commit/Decommit

* Small cleanup
This commit is contained in:
TSRBerry 2023-06-24 02:46:04 +02:00 committed by GitHub
parent bf96bc84a8
commit 7d160e98fd
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
6 changed files with 32 additions and 33 deletions

View file

@ -36,15 +36,15 @@ namespace Ryujinx.Memory
}
}
public static bool Commit(IntPtr address, ulong size, bool forJit)
public static void Commit(IntPtr address, ulong size, bool forJit)
{
if (OperatingSystem.IsWindows())
{
return MemoryManagementWindows.Commit(address, (IntPtr)size);
MemoryManagementWindows.Commit(address, (IntPtr)size);
}
else if (OperatingSystem.IsLinux() || OperatingSystem.IsMacOS())
{
return MemoryManagementUnix.Commit(address, size, forJit);
MemoryManagementUnix.Commit(address, size, forJit);
}
else
{
@ -52,15 +52,15 @@ namespace Ryujinx.Memory
}
}
public static bool Decommit(IntPtr address, ulong size)
public static void Decommit(IntPtr address, ulong size)
{
if (OperatingSystem.IsWindows())
{
return MemoryManagementWindows.Decommit(address, (IntPtr)size);
MemoryManagementWindows.Decommit(address, (IntPtr)size);
}
else if (OperatingSystem.IsLinux() || OperatingSystem.IsMacOS())
{
return MemoryManagementUnix.Decommit(address, size);
MemoryManagementUnix.Decommit(address, size);
}
else
{