From 218675246f1a6b2292b8d4fb5672ba710e47ec9a Mon Sep 17 00:00:00 2001 From: vaxerski <43317083+vaxerski@users.noreply.github.com> Date: Thu, 23 Jun 2022 21:46:36 +0200 Subject: [PATCH] guard pkeyboard in onMouseButton --- src/managers/input/InputManager.cpp | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/src/managers/input/InputManager.cpp b/src/managers/input/InputManager.cpp index 79a13369..46d6338e 100644 --- a/src/managers/input/InputManager.cpp +++ b/src/managers/input/InputManager.cpp @@ -207,6 +207,11 @@ void CInputManager::onMouseButton(wlr_pointer_button_event* e) { const auto PKEYBOARD = wlr_seat_get_keyboard(g_pCompositor->m_sSeat.seat); + if (!PKEYBOARD) { // ??? + Debug::log(ERR, "No active keyboard in onMouseButton??"); + return; + } + switch (e->state) { case WLR_BUTTON_PRESSED: if (!g_pCompositor->m_sSeat.mouse->currentConstraint)