From 095185cfe795fc48a1710eabe9823324fa593fb1 Mon Sep 17 00:00:00 2001 From: vaxerski <43317083+vaxerski@users.noreply.github.com> Date: Thu, 1 Sep 2022 10:15:55 +0200 Subject: [PATCH] guard parent in X11TransientFor --- src/Window.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/Window.cpp b/src/Window.cpp index e7abb6e1..bb0c52e1 100644 --- a/src/Window.cpp +++ b/src/Window.cpp @@ -228,7 +228,7 @@ CWindow* CWindow::X11TransientFor() { auto PPARENT = g_pCompositor->getWindowFromSurface(m_uSurface.xwayland->parent->surface); - while (PPARENT->m_uSurface.xwayland->parent) { + while (g_pCompositor->windowValidMapped(PPARENT) && PPARENT->m_uSurface.xwayland->parent) { PPARENT = g_pCompositor->getWindowFromSurface(PPARENT->m_uSurface.xwayland->parent->surface); }