summaryrefslogtreecommitdiff
path: root/src/managers/input/InputManager.cpp
diff options
context:
space:
mode:
authorVaxry <vaxry@vaxry.net>2024-04-21 15:17:05 +0100
committerVaxry <vaxry@vaxry.net>2024-04-21 15:17:12 +0100
commit93e5d7ca5adb43b1c40b19661a7c0df86c713117 (patch)
treef93c4026b077600ffd6be3d41d3663f13180de88 /src/managers/input/InputManager.cpp
parent1ce21fdb3ec93b38c45b501a30b81dd379429a3e (diff)
input: check for focused_client being null before reading its client
ref #5673
Diffstat (limited to 'src/managers/input/InputManager.cpp')
-rw-r--r--src/managers/input/InputManager.cpp3
1 files changed, 3 insertions, 0 deletions
diff --git a/src/managers/input/InputManager.cpp b/src/managers/input/InputManager.cpp
index 4a7fc11a..bf784af1 100644
--- a/src/managers/input/InputManager.cpp
+++ b/src/managers/input/InputManager.cpp
@@ -13,6 +13,9 @@ CInputManager::CInputManager() {
auto event = std::any_cast<CCursorShapeProtocol::SSetShapeEvent>(data);
+ if (!g_pCompositor->m_sSeat.seat->pointer_state.focused_client)
+ return;
+
if (wl_resource_get_client(event.pMgr->resource()) != g_pCompositor->m_sSeat.seat->pointer_state.focused_client->client)
return;