richardphibel / rpms / systemd

Forked from rpms/systemd 2 years ago
Clone
65878a
From b0010d76a8c56900d15fab8ac1ed94d364d1e566 Mon Sep 17 00:00:00 2001
65878a
From: Lukas Nykryn <lnykryn@redhat.com>
65878a
Date: Wed, 23 Jul 2014 14:08:18 +0200
65878a
Subject: [PATCH] cgroups-agent: down-grade log level
65878a
65878a
(cherry picked from commit 844de4355592259eebcffddfc38c63266e451cb6)
65878a
65878a
Conflicts:
65878a
        src/cgroups-agent/cgroups-agent.c
65878a
65878a
Resolves: #1044386
65878a
---
65878a
 src/cgroups-agent/cgroups-agent.c | 8 ++++++--
65878a
 1 file changed, 6 insertions(+), 2 deletions(-)
65878a
65878a
diff --git a/src/cgroups-agent/cgroups-agent.c b/src/cgroups-agent/cgroups-agent.c
65878a
index a47949a..43b9b3a 100644
65878a
--- a/src/cgroups-agent/cgroups-agent.c
65878a
+++ b/src/cgroups-agent/cgroups-agent.c
65878a
@@ -50,7 +50,11 @@ int main(int argc, char *argv[]) {
65878a
 
65878a
         bus = dbus_connection_open_private("unix:path=/run/systemd/private", &error);
65878a
         if (!bus) {
65878a
-                log_warning("Failed to get D-Bus connection: %s", bus_error_message(&error));
65878a
+                log_warning("Failed to get D-Bus connection: %s", strerror(-r));
65878a
+                /* If we couldn't connect we assume this was triggered
65878a
+                 * while systemd got restarted/transitioned from
65878a
+                 * initrd to the system, so let's ignore this */
65878a
+                log_debug("Failed to get D-Bus connection: %s", strerror(-r));
65878a
                 goto finish;
65878a
         }
65878a
 
65878a
@@ -73,7 +77,7 @@ int main(int argc, char *argv[]) {
65878a
         }
65878a
 
65878a
         if (!dbus_connection_send(bus, m, NULL)) {
65878a
-                log_error("Failed to send signal message on private connection.");
65878a
+                log_debug("Failed to send signal message on private connection.");
65878a
                 goto finish;
65878a
         }
65878a