parent
7de448f2a9
commit
c70c003d48
@ -1,37 +0,0 @@
|
|||||||
From fc01a7f837d06ee9e92d02f13acb79c2b06e9e3c Mon Sep 17 00:00:00 2001
|
|
||||||
From: Fushan Wen <qydwhotmail@gmail.com>
|
|
||||||
Date: Fri, 4 Aug 2023 12:40:17 +0800
|
|
||||||
Subject: [PATCH] shell: avoid potential crash when previous window is gone
|
|
||||||
before returning focus
|
|
||||||
|
|
||||||
m_previousPlasmaWindow is bound to a window, and if a window is closed
|
|
||||||
before `restorePreviousWindow` is called, there will be a crash. Use
|
|
||||||
QPointer to track the window destruction.
|
|
||||||
---
|
|
||||||
shell/shellcorona.h | 3 ++-
|
|
||||||
1 file changed, 2 insertions(+), 1 deletion(-)
|
|
||||||
|
|
||||||
diff --git a/shell/shellcorona.h b/shell/shellcorona.h
|
|
||||||
index a3aff351af..db218d16e2 100644
|
|
||||||
--- a/shell/shellcorona.h
|
|
||||||
+++ b/shell/shellcorona.h
|
|
||||||
@@ -14,6 +14,7 @@
|
|
||||||
|
|
||||||
#include <QDBusContext>
|
|
||||||
#include <QDBusVariant>
|
|
||||||
+#include <QPointer>
|
|
||||||
#include <QSet>
|
|
||||||
#include <QTimer>
|
|
||||||
|
|
||||||
@@ -301,7 +302,7 @@ private:
|
|
||||||
KWayland::Client::PlasmaShell *m_waylandPlasmaShell;
|
|
||||||
// For getting the active window on Wayland
|
|
||||||
KWayland::Client::PlasmaWindowManagement *m_waylandWindowManagement = nullptr;
|
|
||||||
- KWayland::Client::PlasmaWindow *m_previousPlasmaWindow = nullptr;
|
|
||||||
+ QPointer<KWayland::Client::PlasmaWindow> m_previousPlasmaWindow;
|
|
||||||
bool m_closingDown : 1;
|
|
||||||
bool m_screenReorderInProgress = false;
|
|
||||||
QString m_testModeLayout;
|
|
||||||
--
|
|
||||||
GitLab
|
|
||||||
|
|
@ -1,2 +1,2 @@
|
|||||||
SHA512 (breeze-fedora-0.2.tar.gz) = ff800e686b0dcb498f321bb94d3a8274c89c092f5408ef1ec3fc65333f046aea43444144ecaf166792f807014383af87b1180dc7540905fc10dc375309f8b2a8
|
SHA512 (breeze-fedora-0.2.tar.gz) = ff800e686b0dcb498f321bb94d3a8274c89c092f5408ef1ec3fc65333f046aea43444144ecaf166792f807014383af87b1180dc7540905fc10dc375309f8b2a8
|
||||||
SHA512 (plasma-workspace-5.27.7.tar.xz) = 7359d087cb94280ed0c191b0328b8aa2ec42460a6eb057a06bae0de3abcfa8e3cd7c374b47a4b1d08b56fc292892bac4c0f501527574e2c799c3d4c87591892f
|
SHA512 (plasma-workspace-5.27.8.tar.xz) = d75da7d8cea3124f921813643ebda333376d3cc2ecbe2aaeee86e54a828e6a9767fa84b76991cfe282efdbf583abebee4a0bfe54a6b590c184ceb3d2995e9fcb
|
||||||
|
Loading…
Reference in new issue