summaryrefslogtreecommitdiffstats
path: root/src/core/hle/service/hid
diff options
context:
space:
mode:
authorLiam <byteslice@airmail.cc>2024-01-02 23:12:16 +0100
committerLiam <byteslice@airmail.cc>2024-01-13 00:31:33 +0100
commitf90a022d3a20c86399f49a8154847b73bc1b8fd3 (patch)
tree672214411189aaf408febc5aa9cc01e45aed5f5f /src/core/hle/service/hid
parentkernel: fix page leak on process termination (diff)
downloadyuzu-f90a022d3a20c86399f49a8154847b73bc1b8fd3.tar
yuzu-f90a022d3a20c86399f49a8154847b73bc1b8fd3.tar.gz
yuzu-f90a022d3a20c86399f49a8154847b73bc1b8fd3.tar.bz2
yuzu-f90a022d3a20c86399f49a8154847b73bc1b8fd3.tar.lz
yuzu-f90a022d3a20c86399f49a8154847b73bc1b8fd3.tar.xz
yuzu-f90a022d3a20c86399f49a8154847b73bc1b8fd3.tar.zst
yuzu-f90a022d3a20c86399f49a8154847b73bc1b8fd3.zip
Diffstat (limited to 'src/core/hle/service/hid')
-rw-r--r--src/core/hle/service/hid/hid.cpp10
1 files changed, 4 insertions, 6 deletions
diff --git a/src/core/hle/service/hid/hid.cpp b/src/core/hle/service/hid/hid.cpp
index fc03a0a5f..4ce0a9834 100644
--- a/src/core/hle/service/hid/hid.cpp
+++ b/src/core/hle/service/hid/hid.cpp
@@ -22,12 +22,10 @@ void LoopProcess(Core::System& system) {
std::shared_ptr<HidFirmwareSettings> firmware_settings =
std::make_shared<HidFirmwareSettings>();
- // TODO: Remove this hack until this service is emulated properly.
- const auto process_list = system.Kernel().GetProcessList();
- if (!process_list.empty()) {
- resource_manager->Initialize();
- resource_manager->RegisterAppletResourceUserId(process_list[0]->GetId(), true);
- }
+ // TODO: Remove this hack when am is emulated properly.
+ resource_manager->Initialize();
+ resource_manager->RegisterAppletResourceUserId(system.ApplicationProcess()->GetProcessId(),
+ true);
server_manager->RegisterNamedService(
"hid", std::make_shared<IHidServer>(system, resource_manager, firmware_settings));