1
1
mirror of https://github.com/systemd/systemd-stable.git synced 2025-03-08 20:58:20 +03:00

core: log about unit_watch_pid() failing

CID 1237509
This commit is contained in:
Lennart Poettering 2018-10-16 13:47:23 +02:00
parent 2011149a3c
commit cdc2af3e15

View File

@ -3648,7 +3648,11 @@ static void service_notify_message(
}
if (r > 0) {
service_set_main_pid(s, new_main_pid);
unit_watch_pid(UNIT(s), new_main_pid);
r = unit_watch_pid(UNIT(s), new_main_pid);
if (r < 0)
log_unit_warning_errno(UNIT(s), r, "Failed to watch new main PID "PID_FMT" for service: %m", new_main_pid);
notify_dbus = true;
}
}