mirror of
https://github.com/systemd/systemd.git
synced 2025-01-25 10:04:04 +03:00
bus: do not fail if "comm" information cannot be retrieved from /proc
This commit is contained in:
parent
c6dfb87f1d
commit
fa6ccbf423
@ -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) {
|
||||
|
Loading…
x
Reference in New Issue
Block a user