[systemd-commits] src/libsystemd-bus

Kay Sievers kay at kemper.freedesktop.org
Fri Nov 29 12:35:22 PST 2013


 src/libsystemd-bus/bus-creds.c |    6 +++---
 1 file changed, 3 insertions(+), 3 deletions(-)

New commits:
commit fa6ccbf42360cdd794ae3164b76e0cc8f0bd62de
Author: Kay Sievers <kay at vrfy.org>
Date:   Fri Nov 29 21:34:14 2013 +0100

    bus: do not fail if "comm" information cannot be retrieved from /proc

diff --git a/src/libsystemd-bus/bus-creds.c b/src/libsystemd-bus/bus-creds.c
index 22f204f..ea7b1ce 100644
--- a/src/libsystemd-bus/bus-creds.c
+++ b/src/libsystemd-bus/bus-creds.c
@@ -607,10 +607,10 @@ int bus_creds_add_more(sd_bus_creds *c, uint64_t mask, pid_t pid, pid_t tid) {
 
         if (missing & SD_BUS_CREDS_COMM) {
                 r = get_process_comm(pid, &c->comm);
-                if (r < 0)
+                if (r < 0 && r != -ESRCH)
                         return r;
-
-                c->mask |= SD_BUS_CREDS_COMM;
+                else if (r >= 0)
+                        c->mask |= SD_BUS_CREDS_COMM;
         }
 
         if (missing & SD_BUS_CREDS_EXE) {



More information about the systemd-commits mailing list