From b3e76e2cb1c63e4230b478ac12bbb34668538bbd Mon Sep 17 00:00:00 2001 From: Narr the Reg Date: Mon, 1 Jan 2024 21:33:07 -0600 Subject: service: hid: Remove data races when handling shared memory --- src/core/hle/service/hid/controllers/touchscreen.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'src/core/hle/service/hid/controllers/touchscreen.cpp') diff --git a/src/core/hle/service/hid/controllers/touchscreen.cpp b/src/core/hle/service/hid/controllers/touchscreen.cpp index 291dc707e6..b585a5829d 100644 --- a/src/core/hle/service/hid/controllers/touchscreen.cpp +++ b/src/core/hle/service/hid/controllers/touchscreen.cpp @@ -30,7 +30,7 @@ void TouchScreen::OnUpdate(const Core::Timing::CoreTiming& core_timing) { const u64 aruid = applet_resource->GetActiveAruid(); auto* data = applet_resource->GetAruidData(aruid); - if (data == nullptr) { + if (data == nullptr || !data->flag.is_assigned) { return; } -- cgit v1.2.3