systemd: update to 207.

This commit is contained in:
Juan RP 2013-09-13 08:06:36 +02:00
parent d2fd10f9b3
commit 311650d467
4 changed files with 5 additions and 157 deletions

View file

@ -1,71 +0,0 @@
From 76e665855edef5b7103cb09d114377d477bfae02 Mon Sep 17 00:00:00 2001
From: Lennart Poettering <lennart@poettering.net>
Date: Fri, 26 Jul 2013 16:59:46 +0000
Subject: logind: update the session state file before we send out the CreateSession() reply
https://bugs.freedesktop.org/show_bug.cgi?id=67273
---
diff --git a/src/login/logind-dbus.c b/src/login/logind-dbus.c
index b5e975a..7b9bd20 100644
--- src/login/logind-dbus.c
+++ src/login/logind-dbus.c
@@ -2368,9 +2368,8 @@ DBusHandlerResult bus_message_filter(
dbus_set_error(&error, BUS_ERROR_JOB_FAILED, "Start job for unit %s failed with '%s'", unit, result);
session_send_create_reply(s, &error);
}
- }
-
- session_save(s);
+ } else
+ session_save(s);
}
session_add_to_gc_queue(s);
diff --git a/src/login/logind-session-dbus.c b/src/login/logind-session-dbus.c
index 210f756..2cc4d85 100644
--- src/login/logind-session-dbus.c
+++ src/login/logind-session-dbus.c
@@ -592,6 +592,10 @@ int session_send_create_reply(Session *s, DBusError *error) {
return log_oom();
}
+ /* Update the state file before we notify the client about the
+ * result */
+ session_save(s);
+
if (!dbus_connection_send(s->manager->bus, reply, NULL))
return log_oom();
diff --git a/src/machine/machine-dbus.c b/src/machine/machine-dbus.c
index 6e1b8f8..ceab96e 100644
--- src/machine/machine-dbus.c
+++ src/machine/machine-dbus.c
@@ -350,6 +350,10 @@ int machine_send_create_reply(Machine *m, DBusError *error) {
return log_oom();
}
+ /* Update the machine state file before we notify the client
+ * about the result. */
+ machine_save(m);
+
if (!dbus_connection_send(m->manager->bus, reply, NULL))
return log_oom();
diff --git a/src/machine/machined-dbus.c b/src/machine/machined-dbus.c
index 6c4d50b..5a016e7 100644
--- src/machine/machined-dbus.c
+++ src/machine/machined-dbus.c
@@ -551,9 +551,8 @@ DBusHandlerResult bus_message_filter(
dbus_set_error(&error, BUS_ERROR_JOB_FAILED, "Start job for unit %s failed with '%s'", unit, result);
machine_send_create_reply(mm, &error);
}
- }
-
- machine_save(mm);
+ } else
+ machine_save(mm);
}
machine_add_to_gc_queue(mm);
--
cgit v0.9.0.2-2-gbebe

View file

@ -1,77 +0,0 @@
From cba38758b4d49c6fe7c2f0eea255e11ee9df23eb Mon Sep 17 00:00:00 2001
From: Lennart Poettering <lennart@poettering.net>
Date: Fri, 26 Jul 2013 15:32:19 +0000
Subject: logind: update state file after generating the session fifo, not before
https://bugs.freedesktop.org/show_bug.cgi?id=67273
---
diff --git a/src/login/logind-dbus.c b/src/login/logind-dbus.c
index 39af637..b5e975a 100644
--- src/login/logind-dbus.c
+++ src/login/logind-dbus.c
@@ -643,6 +643,10 @@ static int bus_manager_create_session(Manager *m, DBusMessage *message) {
session->create_message = dbus_message_ref(message);
+ /* Now, let's wait until the slice unit and stuff got
+ * created. We send the reply back from
+ * session_send_create_reply().*/
+
return 0;
fail:
@@ -2356,7 +2360,6 @@ DBusHandlerResult bus_message_filter(
if (streq_ptr(path, s->scope_job)) {
free(s->scope_job);
s->scope_job = NULL;
- session_save(s);
if (s->started) {
if (streq(result, "done"))
@@ -2366,6 +2369,8 @@ DBusHandlerResult bus_message_filter(
session_send_create_reply(s, &error);
}
}
+
+ session_save(s);
}
session_add_to_gc_queue(s);
diff --git a/src/login/logind-session-dbus.c b/src/login/logind-session-dbus.c
index 62b9ffd..210f756 100644
--- src/login/logind-session-dbus.c
+++ src/login/logind-session-dbus.c
@@ -535,6 +535,10 @@ int session_send_create_reply(Session *s, DBusError *error) {
if (!s->create_message)
return 0;
+ /* This is called after the session scope was successfully
+ * created, and finishes where bus_manager_create_session()
+ * left off. */
+
if (error) {
DBusError buffer;
diff --git a/src/machine/machined-dbus.c b/src/machine/machined-dbus.c
index 1e8bc60..6c4d50b 100644
--- src/machine/machined-dbus.c
+++ src/machine/machined-dbus.c
@@ -543,7 +543,6 @@ DBusHandlerResult bus_message_filter(
if (streq_ptr(path, mm->scope_job)) {
free(mm->scope_job);
mm->scope_job = NULL;
- machine_save(mm);
if (mm->started) {
if (streq(result, "done"))
@@ -553,6 +552,8 @@ DBusHandlerResult bus_message_filter(
machine_send_create_reply(mm, &error);
}
}
+
+ machine_save(mm);
}
machine_add_to_gc_queue(mm);
--
cgit v0.9.0.2-2-gbebe

View file

@ -1,2 +0,0 @@
cba38758b4d49c6fe7c2f0eea255e11ee9df23eb.patch
76e665855edef5b7103cb09d114377d477bfae02.patch

View file

@ -1,21 +1,20 @@
# Template file for 'systemd'
pkgname=systemd
version=206
revision=3
version=207
revision=1
short_desc="A system and service manager for Linux"
maintainer="Juan RP <xtraeme@gmail.com>"
homepage="http://www.freedesktop.org/wiki/Software/systemd"
license="LGPL-2.1, GPL-2, MIT"
distfiles="http://www.freedesktop.org/software/$pkgname/$pkgname-$version.tar.xz"
checksum=4c993de071118ea1df7ffc4be26ef0b0d78354ef15b2743a2783d20edfcde9de
checksum=ac1f8120315e7969063bbb0c181c8dc59509aeaf10c4266077c257a182ad5942
build_style=gnu-configure
configure_args="--libexecdir=/usr/lib --with-rootprefix=/usr
--disable-selinux --with-sysvinit-path= --with-sysvrcnd-path=
--disable-audit --disable-static --disable-ima"
hostmakedepends="which pkg-config intltool gperf libxslt docbook-xsl
libtool automake gettext-devel"
hostmakedepends="which pkg-config intltool gperf libxslt docbook-xsl libtool"
makedepends="acl-devel pam-devel dbus-devel>=1.6.10_2 libcap-devel libkmod-devel
liblzma-devel cryptsetup-devel libblkid-devel libglib-devel libgcrypt-devel
@ -23,7 +22,6 @@ makedepends="acl-devel pam-devel dbus-devel>=1.6.10_2 libcap-devel libkmod-devel
if [ "$CROSS_BUILD" ]; then
# XXX add support to gudev, introspection and python.
hostmakedepends+=" libgcrypt-devel"
makedepends="acl-devel pam-devel dbus-devel>=1.6.10_2 libcap-devel
libkmod-devel liblzma-devel cryptsetup-devel
libblkid-devel libgcrypt-devel libglib-devel
@ -35,7 +33,7 @@ if [ "$CROSS_BUILD" ]; then
fi
pre_configure() {
autoreconf -fi
libtoolize -f
}
# Package build options