From 66cef35c64fb8795e2500499028550570c321720 Mon Sep 17 00:00:00 2001 From: Xaver Hugl Date: Tue, 26 Sep 2023 17:42:36 +0200 Subject: [PATCH] compositor_wayland: ignore placeholder outputs Placeholder outputs don't have renderloops or output layers. If they're not ignored, KWin crashes --- src/compositor_wayland.cpp | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/src/compositor_wayland.cpp b/src/compositor_wayland.cpp index 687f664e38..aaacd9b68b 100644 --- a/src/compositor_wayland.cpp +++ b/src/compositor_wayland.cpp @@ -245,6 +245,9 @@ void WaylandCompositor::stop() void WaylandCompositor::addOutput(Output *output) { + if (output->isPlaceholder()) { + return; + } auto workspaceLayer = new RenderLayer(output->renderLoop()); workspaceLayer->setDelegate(std::make_unique(m_scene.get(), output)); workspaceLayer->setGeometry(output->rect()); @@ -357,6 +360,9 @@ void WaylandCompositor::addOutput(Output *output) void WaylandCompositor::removeOutput(Output *output) { + if (output->isPlaceholder()) { + return; + } removeSuperLayer(m_superlayers[output->renderLoop()]); }