From ed58eef3ef749a77a51be7d4c2da2e62de3bf623 Mon Sep 17 00:00:00 2001 From: Rex Dieter Date: Thu, 28 Jan 2021 08:25:32 -0600 Subject: [PATCH] pull in upstream fix for autologin (sddm issue #1348) --- ...ng-started-as-the-wrong-type-on-auto.patch | 35 +++++++++++++++++++ ...n-Ensure-SHELL-remains-correctly-set.patch | 4 +-- sddm.spec | 11 +++--- 3 files changed, 44 insertions(+), 6 deletions(-) create mode 100644 0016-Fix-sessions-being-started-as-the-wrong-type-on-auto.patch rename 0001-wayland-session-Ensure-SHELL-remains-correctly-set.patch => 0018-wayland-session-Ensure-SHELL-remains-correctly-set.patch (88%) diff --git a/0016-Fix-sessions-being-started-as-the-wrong-type-on-auto.patch b/0016-Fix-sessions-being-started-as-the-wrong-type-on-auto.patch new file mode 100644 index 0000000..665001f --- /dev/null +++ b/0016-Fix-sessions-being-started-as-the-wrong-type-on-auto.patch @@ -0,0 +1,35 @@ +From e81dfcd6913c4fbd1801597168291b1e396633d8 Mon Sep 17 00:00:00 2001 +From: Fabian Vogt +Date: Wed, 6 Jan 2021 16:00:34 +0100 +Subject: [PATCH 16/18] Fix sessions being started as the wrong type on + autologin + +For autologin, the last session is used, which contains a full path. +Display::findSessionEntry didn't handle that correctly, which led to +X11 sessions getting started as Wayland ones (or the other way around +before 994fa67). + +Fixes #1348 +--- + src/daemon/Display.cpp | 5 +++++ + 1 file changed, 5 insertions(+) + +diff --git a/src/daemon/Display.cpp b/src/daemon/Display.cpp +index b95f6e5..9f1fabc 100644 +--- a/src/daemon/Display.cpp ++++ b/src/daemon/Display.cpp +@@ -245,6 +245,11 @@ namespace SDDM { + } + + bool Display::findSessionEntry(const QDir &dir, const QString &name) const { ++ // Given an absolute path: Check that it matches dir ++ const QFileInfo fileInfo(name); ++ if (fileInfo.isAbsolute() && fileInfo.absolutePath() != dir.absolutePath()) ++ return false; ++ + QString fileName = name; + + // append extension +-- +2.29.2 + diff --git a/0001-wayland-session-Ensure-SHELL-remains-correctly-set.patch b/0018-wayland-session-Ensure-SHELL-remains-correctly-set.patch similarity index 88% rename from 0001-wayland-session-Ensure-SHELL-remains-correctly-set.patch rename to 0018-wayland-session-Ensure-SHELL-remains-correctly-set.patch index a15f4a1..8ebbef1 100644 --- a/0001-wayland-session-Ensure-SHELL-remains-correctly-set.patch +++ b/0018-wayland-session-Ensure-SHELL-remains-correctly-set.patch @@ -1,7 +1,7 @@ -From 0cd4e54b4a8656d9e131decc2cb9ca86bf82e81a Mon Sep 17 00:00:00 2001 +From bc5a18f34c0881929a6b2e5d3993971c4f692f4f Mon Sep 17 00:00:00 2001 From: Neal Gompa Date: Sun, 17 Jan 2021 11:48:28 -0500 -Subject: [PATCH] wayland-session: Ensure $SHELL remains correctly set +Subject: [PATCH 18/18] wayland-session: Ensure $SHELL remains correctly set In some circumstances, the effort of setting the environment correctly can wind up clobbering the user-specified shell. To diff --git a/sddm.spec b/sddm.spec index 7482895..20ce2d5 100644 --- a/sddm.spec +++ b/sddm.spec @@ -9,7 +9,7 @@ Name: sddm Version: 0.19.0 -Release: 4%{?dist} +Release: 5%{?dist} License: GPLv2+ Summary: QML based X11 desktop manager @@ -18,6 +18,9 @@ Source0: %{url}/archive/v%{version}/%{name}-%{version}.tar.gz ## upstream patches +Patch16: 0016-Fix-sessions-being-started-as-the-wrong-type-on-auto.patch +Patch18: 0018-wayland-session-Ensure-SHELL-remains-correctly-set.patch + ## upstreamable patches # From: https://github.com/sddm/sddm/pull/997 @@ -26,9 +29,6 @@ Patch051: 0001-Remove-suffix-for-Wayland-session.patch # From: https://github.com/sddm/sddm/pull/1230 Patch052: 0001-Redesign-Xauth-handling.patch -# From: https://github.com/sddm/sddm/pull/1360 -Patch053: 0001-wayland-session-Ensure-SHELL-remains-correctly-set.patch - ## downstream patches Patch101: sddm-0.19.0-fedora_config.patch @@ -223,6 +223,9 @@ fi %changelog +* Thu Jan 28 2021 Rex Dieter - 0.19.0-5 +- pull in upstream fix for autologin (sddm issue #1348) + * Tue Jan 26 2021 Rex Dieter - 0.19.0-4 - Refresh Xauth patch from upstream PR - minor .spec cosmetics