kde-plasma/plasma-workspace: backport patch from upstream solving lock screen bypass
authorMichael Palimaka <kensington@gentoo.org>
Tue, 9 Feb 2016 16:13:10 +0000 (03:13 +1100)
committerMichael Palimaka <kensington@gentoo.org>
Tue, 9 Feb 2016 16:25:14 +0000 (03:25 +1100)
Gentoo-bug: 574270

Package-Manager: portage-2.2.27

kde-plasma/plasma-workspace/files/plasma-workspace-5.4.3-lockscreen-bypass.patch [new file with mode: 0644]
kde-plasma/plasma-workspace/plasma-workspace-5.4.3-r2.ebuild [moved from kde-plasma/plasma-workspace/plasma-workspace-5.4.3-r1.ebuild with 99% similarity]

diff --git a/kde-plasma/plasma-workspace/files/plasma-workspace-5.4.3-lockscreen-bypass.patch b/kde-plasma/plasma-workspace/files/plasma-workspace-5.4.3-lockscreen-bypass.patch
new file mode 100644 (file)
index 0000000..977251e
--- /dev/null
@@ -0,0 +1,38 @@
+From 23a9ed7ba9995570227dbcd69c23f009de7dde49 Mon Sep 17 00:00:00 2001
+From: =?UTF-8?q?Martin=20Gr=C3=A4=C3=9Flin?= <mgraesslin@kde.org>
+Date: Tue, 9 Feb 2016 16:37:50 +0100
+Subject: [PATCH] [greeter] Dont quit when last window closes
+
+Qt allows to have no screens. If all XRandR screens are disconnected
+there are also no QScreens. This is from an X11 perspective wrong, but
+we have to deal with it. No QScreens means that all views are destroyed
+and no new ones are created. Thus all windows close and the greeter
+exited successfully which in turn unlocked the screen.
+
+This change ensures that the greeter doesn't exit when all windows close.
+
+Funnily this was not a problem with the well known issue of Qt
+crashing when all screens are disconnected. The lock screen handles
+crashes gracefully and just restarts or more likely Qt also crashes
+the application using KSld and thus taking down the complete session.
+
+CCBUG: 358125
+---
+ ksmserver/screenlocker/greeter/main.cpp | 1 +
+ 1 file changed, 1 insertion(+)
+
+diff --git a/ksmserver/screenlocker/greeter/main.cpp b/ksmserver/screenlocker/greeter/main.cpp
+index fa4bf62..0a68835 100644
+--- a/ksmserver/screenlocker/greeter/main.cpp
++++ b/ksmserver/screenlocker/greeter/main.cpp
+@@ -56,6 +56,7 @@ int main(int argc, char* argv[])
+     // explicitly disable input methods as it makes it impossible to unlock, see BUG 306932
+     qputenv("QT_IM_MODULE", QByteArrayLiteral("compose"));
+     ScreenLocker::UnlockApp app(argc, argv);
++    app.setQuitOnLastWindowClosed(false);
+     QCoreApplication::setApplicationName(QStringLiteral("kscreenlocker_greet"));
+     QCoreApplication::setApplicationVersion(QStringLiteral("0.1"));
+     QCoreApplication::setOrganizationDomain(QStringLiteral("kde.org"));
+-- 
+2.4.10
+
similarity index 99%
rename from kde-plasma/plasma-workspace/plasma-workspace-5.4.3-r1.ebuild
rename to kde-plasma/plasma-workspace/plasma-workspace-5.4.3-r2.ebuild
index b6f96f5586d18442daf4db1b2684502192add9f2..0b95d6e9c8a916e31188b062b25fde319a21acb1 100644 (file)
@@ -130,6 +130,7 @@ PATCHES=(
        "${FILESDIR}/${PN}-5.4-consolekit2.patch"
        "${FILESDIR}/${PN}-5.4.3-fix-drkonqi.patch"     #Upstream bug 354110
        "${FILESDIR}/${PN}-5.4.3-no-SUID-no-GUID.patch"
+       "${FILESDIR}/${P}-lockscreen-bypass.patch"
 )
 
 RESTRICT="test"