diff options
author | V3n3RiX <venerix@koprulu.sector> | 2022-07-26 14:59:08 +0100 |
---|---|---|
committer | V3n3RiX <venerix@koprulu.sector> | 2022-07-26 14:59:08 +0100 |
commit | 1503b28e7a30c164cab750c27268f704b8a5cec6 (patch) | |
tree | d06a47a18b0fb792e95f88ea6e18af234eb0b9d5 /kde-frameworks/plasma/files | |
parent | 34ce8f465101950c92cb66c657d3244b5a8397db (diff) |
gentoo auto-resync : 26:07:2022 - 14:59:07
Diffstat (limited to 'kde-frameworks/plasma/files')
-rw-r--r-- | kde-frameworks/plasma/files/plasma-5.96.0-fix-crash-in-WindowShadowTile.patch | 55 |
1 files changed, 55 insertions, 0 deletions
diff --git a/kde-frameworks/plasma/files/plasma-5.96.0-fix-crash-in-WindowShadowTile.patch b/kde-frameworks/plasma/files/plasma-5.96.0-fix-crash-in-WindowShadowTile.patch new file mode 100644 index 000000000000..8d37a508b359 --- /dev/null +++ b/kde-frameworks/plasma/files/plasma-5.96.0-fix-crash-in-WindowShadowTile.patch @@ -0,0 +1,55 @@ +From 50eaece7aef004b588a684c9fadff0f6787f2ef8 Mon Sep 17 00:00:00 2001 +From: David Edmundson <kde@davidedmundson.co.uk> +Date: Thu, 14 Jul 2022 22:45:14 +0100 +Subject: [PATCH] Scope DialogShadows lifetime to application + +- DialogShadows own KWayland::Client::buffer objects + - Buffer cleanup makes wayland calls + - wayland calls after QGuiApplication has stoped will fail + +Q_GLOBAL_STATIC mangaged objects can outlive the QGuiApplication. + +BUG:443706 +--- + src/plasmaquick/dialogshadows.cpp | 18 ++++++------------ + 1 file changed, 6 insertions(+), 12 deletions(-) + +diff --git a/src/plasmaquick/dialogshadows.cpp b/src/plasmaquick/dialogshadows.cpp +index 17c9a41e2..93b9bcc0f 100644 +--- a/src/plasmaquick/dialogshadows.cpp ++++ b/src/plasmaquick/dialogshadows.cpp +@@ -37,17 +37,6 @@ public: + QVector<KWindowShadowTile::Ptr> m_tiles; + }; + +-class DialogShadowsSingleton +-{ +-public: +- DialogShadowsSingleton() +- { +- } +- +- DialogShadows self; +-}; +- +-Q_GLOBAL_STATIC(DialogShadowsSingleton, privateDialogShadowsSelf) + + DialogShadows::DialogShadows(QObject *parent, const QString &prefix) + : Plasma::Svg(parent) +@@ -64,7 +53,12 @@ DialogShadows::~DialogShadows() + + DialogShadows *DialogShadows::self() + { +- return &privateDialogShadowsSelf->self; ++ // KF6 port to Q_APPLICATION_STATIC ++ static DialogShadows *s_privateDialogShadowsSelf = nullptr; ++ if (!s_privateDialogShadowsSelf) { ++ s_privateDialogShadowsSelf = new DialogShadows(qApp); ++ } ++ return s_privateDialogShadowsSelf; + } + + void DialogShadows::addWindow(QWindow *window, Plasma::FrameSvg::EnabledBorders enabledBorders) +-- +GitLab + |