From b44f33c7ed2ac22079c174c4e38d2f8170b527c0 Mon Sep 17 00:00:00 2001 From: Aleix Pol Date: Fri, 5 Nov 2021 23:54:48 +0100 Subject: [PATCH] DecorationItem: Prevent crash We are calling a QPointer without checking it first. --- src/decorationitem.cpp | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/src/decorationitem.cpp b/src/decorationitem.cpp index 23fcb79462..3d1df393f8 100644 --- a/src/decorationitem.cpp +++ b/src/decorationitem.cpp @@ -45,7 +45,9 @@ Decoration::DecoratedClientImpl *DecorationRenderer::client() const void DecorationRenderer::invalidate() { - addDamage(m_client->client()->rect()); + if (m_client) { + addDamage(m_client->client()->rect()); + } m_imageSizesDirty = true; }