mirror of
https://github.com/hyprwm/Hyprland
synced 2024-11-23 06:25:58 +01:00
Protect against crash in focusWindow
This commit is contained in:
parent
e8a432e979
commit
deb18af955
1 changed files with 4 additions and 4 deletions
|
@ -402,13 +402,13 @@ void CCompositor::focusWindow(CWindow* pWindow, wlr_surface* pSurface) {
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
if (pWindow->m_bNoFocus) {
|
if (!pWindow || !windowValidMapped(pWindow)) {
|
||||||
Debug::log(LOG, "Ignoring focus to nofocus window!");
|
wlr_seat_keyboard_notify_clear_focus(m_sSeat.seat);
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
if (!pWindow || !windowValidMapped(pWindow)) {
|
if (pWindow->m_bNoFocus) {
|
||||||
wlr_seat_keyboard_notify_clear_focus(m_sSeat.seat);
|
Debug::log(LOG, "Ignoring focus to nofocus window!");
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue