commit: f0f302d5e88ff226747a84b927cf67ab59929f5f
Author: Michael Palimaka <kensington <AT> gentoo <DOT> org>
AuthorDate: Thu Jun 16 11:55:05 2016 +0000
Commit: Michael Palimaka <kensington <AT> gentoo <DOT> org>
CommitDate: Thu Jun 16 12:01:28 2016 +0000
URL: https://gitweb.gentoo.org/proj/kde.git/commit/?id=f0f302d5
sys-auth/elogind: backport patch from upstream to solve an issue with sessions
not being saved
Package-Manager: portage-2.3.0_rc1
...d-219.12-r1.ebuild => elogind-219.12-r2.ebuild} | 1 +
.../elogind/files/elogind-219.12-session.patch | 45 ++++++++++++++++++++++
2 files changed, 46 insertions(+)
diff --git a/sys-auth/elogind/elogind-219.12-r1.ebuild
b/sys-auth/elogind/elogind-219.12-r2.ebuild
similarity index 97%
rename from sys-auth/elogind/elogind-219.12-r1.ebuild
rename to sys-auth/elogind/elogind-219.12-r2.ebuild
index b880f9f..d613a2b 100644
--- a/sys-auth/elogind/elogind-219.12-r1.ebuild
+++ b/sys-auth/elogind/elogind-219.12-r2.ebuild
@@ -41,6 +41,7 @@ DOCS=( NEWS README TODO )
PATCHES=(
"${FILESDIR}/${PN}-docs.patch"
"${FILESDIR}/${PN}-lrt.patch"
+ "${FILESDIR}/${P}-session.patch"
)
src_prepare() {
diff --git a/sys-auth/elogind/files/elogind-219.12-session.patch
b/sys-auth/elogind/files/elogind-219.12-session.patch
new file mode 100644
index 0000000..82cbebd
--- /dev/null
+++ b/sys-auth/elogind/files/elogind-219.12-session.patch
@@ -0,0 +1,45 @@
+From b5c5dd2ad43a3bf4fa0fb21139f8d16959b5d14e Mon Sep 17 00:00:00 2001
+From: Andy Wingo <[email protected]>
+Date: Sun, 6 Mar 2016 16:56:33 +0100
+Subject: [PATCH] Fixes to user and session saving
+
+* src/login/logind-dbus.c (method_create_session): No need to save
+ session here, as session_send_create_reply will do it.
+* src/login/logind-session-dbus.c (session_send_create_reply): On the
+ other hand we do need to save the user here, so the file marks them as
+ being active.
+---
+ src/login/logind-dbus.c | 2 --
+ src/login/logind-session-dbus.c | 5 +++--
+ 2 files changed, 3 insertions(+), 4 deletions(-)
+
+diff --git a/src/login/logind-dbus.c b/src/login/logind-dbus.c
+index 5e6952d..6f7e569 100644
+--- a/src/login/logind-dbus.c
++++ b/src/login/logind-dbus.c
+@@ -801,8 +801,6 @@ static int method_create_session(sd_bus *bus,
sd_bus_message *message, void *use
+ if (r < 0)
+ goto fail;
+
+- session_save(session);
+-
+ return 1;
+
+ fail:
+diff --git a/src/login/logind-session-dbus.c b/src/login/logind-session-dbus.c
+index f71798b..337bbbb 100644
+--- a/src/login/logind-session-dbus.c
++++ b/src/login/logind-session-dbus.c
+@@ -721,9 +721,10 @@ int session_send_create_reply(Session *s, sd_bus_error
*error) {
+ if (fifo_fd < 0)
+ return fifo_fd;
+
+- /* Update the session state file before we notify the client
+- * about the result. */
++ /* Update the session and user state files before we notify
++ * the client about the result. */
+ session_save(s);
++ user_save(s->user);
+
+ p = session_bus_path(s);
+ if (!p)