2013-01-23 14:44:07 +01:00
|
|
|
From d255133d8edc84662d2370a77414505a800d1922 Mon Sep 17 00:00:00 2001
|
|
|
|
From: Lennart Poettering <lennart@poettering.net>
|
|
|
|
Date: Sat, 12 Jan 2013 00:00:22 +0100
|
|
|
|
Subject: [PATCH] systemctl: don't hit an assert if we try to reboot and dbus
|
|
|
|
is dead
|
|
|
|
|
|
|
|
https://bugzilla.redhat.com/show_bug.cgi?id=889624
|
|
|
|
---
|
|
|
|
src/systemctl/systemctl.c | 3 +++
|
|
|
|
1 file changed, 3 insertions(+)
|
|
|
|
|
2013-03-20 11:29:34 +01:00
|
|
|
Index: systemd-195/src/systemctl/systemctl.c
|
|
|
|
===================================================================
|
|
|
|
--- systemd-195.orig/src/systemctl/systemctl.c
|
|
|
|
+++ systemd-195/src/systemctl/systemctl.c
|
|
|
|
@@ -1744,6 +1744,9 @@ static int reboot_with_logind(DBusConnec
|
2013-01-23 14:44:07 +01:00
|
|
|
const char *method;
|
|
|
|
dbus_bool_t interactive = true;
|
|
|
|
|
|
|
|
+ if (!bus)
|
|
|
|
+ return -EIO;
|
|
|
|
+
|
|
|
|
polkit_agent_open_if_enabled();
|
|
|
|
|
|
|
|
switch (a) {
|