summaryrefslogtreecommitdiffstats
path: root/src/compositor/extensions/qwaylandwlshell.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'src/compositor/extensions/qwaylandwlshell.cpp')
-rw-r--r--src/compositor/extensions/qwaylandwlshell.cpp3
1 files changed, 2 insertions, 1 deletions
diff --git a/src/compositor/extensions/qwaylandwlshell.cpp b/src/compositor/extensions/qwaylandwlshell.cpp
index aa8a93aff..6eb1c06e4 100644
--- a/src/compositor/extensions/qwaylandwlshell.cpp
+++ b/src/compositor/extensions/qwaylandwlshell.cpp
@@ -457,7 +457,8 @@ QWaylandWlShellSurface::QWaylandWlShellSurface(QWaylandWlShell *shell, QWaylandS
QWaylandWlShellSurface::~QWaylandWlShellSurface()
{
Q_D(QWaylandWlShellSurface);
- QWaylandWlShellPrivate::get(d->m_shell)->unregisterShellSurface(this);
+ if (d->m_shell)
+ QWaylandWlShellPrivate::get(d->m_shell)->unregisterShellSurface(this);
}
/*!