From 62af35c42b8a13e00b356d1a30904f295e24b768 Mon Sep 17 00:00:00 2001 From: wheremyfoodat <44909372+wheremyfoodat@users.noreply.github.com> Date: Sun, 12 Nov 2023 21:24:12 +0200 Subject: [PATCH] [Applet Manager] Fix resetting --- src/core/applets/applet_manager.cpp | 2 ++ src/core/services/apt.cpp | 2 +- 2 files changed, 3 insertions(+), 1 deletion(-) diff --git a/src/core/applets/applet_manager.cpp b/src/core/applets/applet_manager.cpp index 4c2410279..c27917777 100644 --- a/src/core/applets/applet_manager.cpp +++ b/src/core/applets/applet_manager.cpp @@ -7,6 +7,8 @@ using namespace Applets; AppletManager::AppletManager(Memory& mem) : miiSelector(mem, nextParameter), swkbd(mem, nextParameter) {} void AppletManager::reset() { + nextParameter = std::nullopt; + miiSelector.reset(); swkbd.reset(); } diff --git a/src/core/services/apt.cpp b/src/core/services/apt.cpp index 0fc2bb8ad..754baa139 100644 --- a/src/core/services/apt.cpp +++ b/src/core/services/apt.cpp @@ -291,7 +291,7 @@ void APTService::glanceParameter(u32 messagePointer) { // Sender App ID mem.write32(messagePointer + 8, parameter.senderID); // Command - mem.write32(messagePointer + 12, static_cast(parameter.signal)); + mem.write32(messagePointer + 12, parameter.signal); // Size of parameter data mem.write32(messagePointer + 16, parameter.data.size()); mem.write32(messagePointer + 20, 0);