0001-Read-the-DISPLAYMANAGER_AUTOLOGIN-value-from-sysconf.patch to 00-general.conf - Add patches to make autologin with wayland more reliable (boo#1221507): * 0001-Remove-unused-Display-m_relogin-variable.patch * 0002-Set-Display-m_started-early.patch * 0003-Load-autologin-configuration-in-Display-Display.patch * 0004-Reset-daemonApp-first-in-the-Display-constructor.patch * 0005-If-autologin-is-used-avoid-starting-a-display-server.patch - Rebase 0001-Read-the-DISPLAYMANAGER_AUTOLOGIN-value-from-sysconf.patch OBS-URL: https://build.opensuse.org/package/show/KDE:Frameworks5/sddm?expand=0&rev=187
72 lines
2.1 KiB
Diff
72 lines
2.1 KiB
Diff
From 1e56412d495b13b469f9a73efdc99701d48b831e Mon Sep 17 00:00:00 2001
|
|
From: Fabian Vogt <fabian@ritter-vogt.de>
|
|
Date: Mon, 15 Jul 2024 21:10:12 +0200
|
|
Subject: [PATCH 2/5] Set Display::m_started early
|
|
|
|
It's only read to check whether start() and stop() should do anything,
|
|
so set it true as soon as it attempted to start anything.
|
|
---
|
|
src/daemon/Display.cpp | 18 ++++++------------
|
|
1 file changed, 6 insertions(+), 12 deletions(-)
|
|
|
|
diff --git a/src/daemon/Display.cpp b/src/daemon/Display.cpp
|
|
index 1a0a369..91e4dac 100644
|
|
--- a/src/daemon/Display.cpp
|
|
+++ b/src/daemon/Display.cpp
|
|
@@ -205,7 +205,12 @@ namespace SDDM {
|
|
}
|
|
|
|
bool Display::start() {
|
|
- return m_started || m_displayServer->start();
|
|
+ if (m_started)
|
|
+ return true;
|
|
+
|
|
+ m_started = true;
|
|
+
|
|
+ return m_displayServer->start();
|
|
}
|
|
|
|
bool Display::attemptAutologin() {
|
|
@@ -256,9 +261,6 @@ namespace SDDM {
|
|
|
|
// reset first flag
|
|
daemonApp->first = false;
|
|
-
|
|
- // set flags
|
|
- m_started = true;
|
|
}
|
|
|
|
void Display::handleAutologinFailure() {
|
|
@@ -268,10 +270,6 @@ namespace SDDM {
|
|
}
|
|
|
|
void Display::displayServerStarted() {
|
|
- // check flag
|
|
- if (m_started)
|
|
- return;
|
|
-
|
|
// setup display
|
|
m_displayServer->setupDisplay();
|
|
|
|
@@ -283,9 +281,6 @@ namespace SDDM {
|
|
// reset first flag
|
|
daemonApp->first = false;
|
|
|
|
- // set flags
|
|
- m_started = true;
|
|
-
|
|
const bool autologinStarted = attemptAutologin();
|
|
if (!autologinStarted)
|
|
handleAutologinFailure();
|
|
@@ -484,7 +479,6 @@ namespace SDDM {
|
|
OrgFreedesktopLogin1ManagerInterface manager(Logind::serviceName(), Logind::managerPath(), QDBusConnection::systemBus());
|
|
manager.UnlockSession(m_reuseSessionId);
|
|
manager.ActivateSession(m_reuseSessionId);
|
|
- m_started = true;
|
|
} else {
|
|
if (qobject_cast<XorgDisplayServer *>(m_displayServer))
|
|
m_auth->setCookie(qobject_cast<XorgDisplayServer *>(m_displayServer)->cookie());
|
|
--
|
|
2.46.0
|
|
|