diff options
Diffstat (limited to '.patches-to-be-ported-from-slick-greeter/0062-Allow-wayland-sessions-to-pass-validation.patch')
-rw-r--r-- | .patches-to-be-ported-from-slick-greeter/0062-Allow-wayland-sessions-to-pass-validation.patch | 43 |
1 files changed, 43 insertions, 0 deletions
diff --git a/.patches-to-be-ported-from-slick-greeter/0062-Allow-wayland-sessions-to-pass-validation.patch b/.patches-to-be-ported-from-slick-greeter/0062-Allow-wayland-sessions-to-pass-validation.patch new file mode 100644 index 0000000..e3c4889 --- /dev/null +++ b/.patches-to-be-ported-from-slick-greeter/0062-Allow-wayland-sessions-to-pass-validation.patch @@ -0,0 +1,43 @@ +From e6a649d20b926e9b82ea21af384c997636a90c9e Mon Sep 17 00:00:00 2001 +From: Ivan Podogov <ginkage@yandex.ru> +Date: Wed, 28 Dec 2022 12:35:51 +0000 +Subject: [PATCH 62/81] Allow wayland sessions to pass validation + +This makes slick-greeter properly remember the last wayland session instead of defaulting to an xsession. + +Signed-off-by: Mike Gabriel <mike.gabriel@das-netzwerkteam.de> +--- + src/slick-greeter.vala | 10 +++++++++- + 1 file changed, 9 insertions(+), 1 deletion(-) + +diff --git a/src/slick-greeter.vala b/src/slick-greeter.vala +index d1b9815..44661b5 100644 +--- a/src/slick-greeter.vala ++++ b/src/slick-greeter.vala +@@ -204,6 +204,13 @@ public class SlickGreeter + } + } + ++ foreach (string session in sessions) { ++ var path = Path.build_filename ("/usr/share/wayland-sessions/", session.concat(".desktop"), null); ++ if (FileUtils.test (path, FileTest.EXISTS)) { ++ return session; ++ } ++ } ++ + warning ("Could not find a default session."); + return null; + } +@@ -214,7 +221,8 @@ public class SlickGreeter + otherwise, return the default session. */ + if (session != null) { + var path = Path.build_filename ("/usr/share/xsessions/", session.concat(".desktop"), null); +- if (!FileUtils.test (path, FileTest.EXISTS) ) { ++ var waypath = Path.build_filename ("/usr/share/wayland-sessions/", session.concat(".desktop"), null); ++ if (!FileUtils.test (path, FileTest.EXISTS) & !FileUtils.test (waypath, FileTest.EXISTS)) { + debug ("Invalid session: '%s'", session); + session = null; + } +-- +2.30.2 + |