From b8870e4cb5cedd5edee5225d290a4e0ce222ce1b Mon Sep 17 00:00:00 2001 From: Duncan Ogilvie Date: Sat, 2 May 2026 13:48:02 +0200 Subject: [PATCH] Fix compilation errors in Dna.Emulation.Unicorn --- Dna/Emulation/Unicorn/GdtHelper.cs | 2 +- Dna/Emulation/Unicorn/UnicornEmulator.cs | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/Dna/Emulation/Unicorn/GdtHelper.cs b/Dna/Emulation/Unicorn/GdtHelper.cs index fba491d..b6f502a 100644 --- a/Dna/Emulation/Unicorn/GdtHelper.cs +++ b/Dna/Emulation/Unicorn/GdtHelper.cs @@ -87,7 +87,7 @@ namespace Dna.Emulation.Unicorn var gdtEntry = CreateGdtEntry(segAddr, segSize, access, F_PROT_32); var bytes = BitConverter.GetBytes(gdtEntry); - emu.Memory.Write(gdtAddress + 8 * gdtIdx, bytes, (ulong)bytes.Length); + emu.Memory.Write(gdtAddress + 8 * gdtIdx, bytes, bytes.Length); var selector = CreateSelector(gdtIdx, S_GDT | S_PRIV_0); diff --git a/Dna/Emulation/Unicorn/UnicornEmulator.cs b/Dna/Emulation/Unicorn/UnicornEmulator.cs index 255bfb2..8693396 100644 --- a/Dna/Emulation/Unicorn/UnicornEmulator.cs +++ b/Dna/Emulation/Unicorn/UnicornEmulator.cs @@ -105,7 +105,7 @@ namespace Dna.Emulation.Unicorn public void WriteMemory(ulong addr, byte[] buffer) { - Emulator.Memory.Write(addr, buffer, (ulong)buffer.Length); + Emulator.Memory.Write(addr, buffer, buffer.Length); } public void Start(ulong addr, ulong untilAddr = long.MaxValue)