From 41cce9b9d007e86b5dfe335a309e2f2088a7e0b0 Mon Sep 17 00:00:00 2001 From: Starlet Date: Sun, 21 Apr 2019 13:16:01 -0400 Subject: [PATCH] Whoops --- Ryujinx.HLE/HOS/Services/Time/IStaticService.cs | 10 ++-------- 1 file changed, 2 insertions(+), 8 deletions(-) diff --git a/Ryujinx.HLE/HOS/Services/Time/IStaticService.cs b/Ryujinx.HLE/HOS/Services/Time/IStaticService.cs index 398c99583d..d3ce422dd8 100644 --- a/Ryujinx.HLE/HOS/Services/Time/IStaticService.cs +++ b/Ryujinx.HLE/HOS/Services/Time/IStaticService.cs @@ -15,9 +15,7 @@ namespace Ryujinx.HLE.HOS.Services.Time private static readonly DateTime StartupDate = DateTime.UtcNow; - private KSharedMemory _timeSharedMem; - - public IStaticService(KSharedMemory timeSharedMem) + public IStaticService() { _commands = new Dictionary { @@ -29,8 +27,6 @@ namespace Ryujinx.HLE.HOS.Services.Time { 20, GetSharedMemoryNativeHandle }, { 300, CalculateMonotonicSystemClockBaseTimePoint } }; - - _timeSharedMem = timeSharedMem; } public long GetStandardUserSystemClock(ServiceCtx context) @@ -70,9 +66,7 @@ namespace Ryujinx.HLE.HOS.Services.Time public long GetSharedMemoryNativeHandle(ServiceCtx context) { - KHandleTable handleTable = context.Process.HandleTable; - - if (handleTable.GenerateHandle(_timeSharedMem, out int handle) != KernelResult.Success) + if (context.Process.HandleTable.GenerateHandle(context.Device.System.TimeSharedMem, out int handle) != KernelResult.Success) { throw new InvalidOperationException("Out of handles!"); }