summaryrefslogtreecommitdiffstats
path: root/src/plugins/shellintegration/xdg-shell-v5/qwaylandxdgshellv5.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'src/plugins/shellintegration/xdg-shell-v5/qwaylandxdgshellv5.cpp')
-rw-r--r--src/plugins/shellintegration/xdg-shell-v5/qwaylandxdgshellv5.cpp3
1 files changed, 3 insertions, 0 deletions
diff --git a/src/plugins/shellintegration/xdg-shell-v5/qwaylandxdgshellv5.cpp b/src/plugins/shellintegration/xdg-shell-v5/qwaylandxdgshellv5.cpp
index 4cbafbd71..3eda43d7c 100644
--- a/src/plugins/shellintegration/xdg-shell-v5/qwaylandxdgshellv5.cpp
+++ b/src/plugins/shellintegration/xdg-shell-v5/qwaylandxdgshellv5.cpp
@@ -71,6 +71,9 @@ QWaylandXdgSurfaceV5 *QWaylandXdgShellV5::createXdgSurface(QWaylandWindow *windo
QWaylandXdgPopupV5 *QWaylandXdgShellV5::createXdgPopup(QWaylandWindow *window, QWaylandInputDevice *inputDevice)
{
QWaylandWindow *parentWindow = m_popups.empty() ? window->transientParent() : m_popups.last();
+ if (!parentWindow)
+ return nullptr;
+
::wl_surface *parentSurface = parentWindow->object();
if (m_popupSerial == 0)