From bb74aeae54e4579008ac23216b8b175d64c9f10f Mon Sep 17 00:00:00 2001 From: Ac_K Date: Sat, 23 Nov 2019 03:15:15 +0100 Subject: Use BinaryPrimitives.ReverseEndianness instead EndianSwap class (#832) This PR remove the `EndianSwap` class who isn't needed anymore since .NET Core 3.0 got a buildin method `BinaryPrimitives.ReverseEndianness` who did the same thing. --- Ryujinx.HLE/HOS/Font/SharedFontManager.cs | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) (limited to 'Ryujinx.HLE/HOS/Font/SharedFontManager.cs') diff --git a/Ryujinx.HLE/HOS/Font/SharedFontManager.cs b/Ryujinx.HLE/HOS/Font/SharedFontManager.cs index 40a81b86..99b662c0 100644 --- a/Ryujinx.HLE/HOS/Font/SharedFontManager.cs +++ b/Ryujinx.HLE/HOS/Font/SharedFontManager.cs @@ -5,6 +5,7 @@ using Ryujinx.Common; using Ryujinx.HLE.Exceptions; using Ryujinx.HLE.FileSystem; using Ryujinx.HLE.FileSystem.Content; +using System.Buffers.Binary; using System.Collections.Generic; using System.IO; @@ -142,7 +143,7 @@ namespace Ryujinx.HLE.HOS.Font const int decMagic = 0x18029a7f; const int key = 0x49621806; - int encryptedSize = EndianSwap.Swap32(size ^ key); + int encryptedSize = BinaryPrimitives.ReverseEndianness(size ^ key); _device.Memory.WriteInt32(position + 0, decMagic); _device.Memory.WriteInt32(position + 4, encryptedSize); -- cgit v1.2.3