mirror of
https://github.com/systemd/systemd.git
synced 2025-01-11 09:18:07 +03:00
service: don't bother with watching PIDs during deserialization
service_coldplug() takes care of that anyway, hence drop the unit_watch_pid() invocation entirely during serialization, it's redundant.
This commit is contained in:
parent
62a769136d
commit
eabd3e56a6
@ -2639,12 +2639,8 @@ static int service_deserialize_item(Unit *u, const char *key, const char *value,
|
||||
|
||||
if (parse_pid(value, &pid) < 0)
|
||||
log_unit_debug(u, "Failed to parse main-pid value: %s", value);
|
||||
else {
|
||||
service_set_main_pid(s, pid);
|
||||
r = unit_watch_pid(UNIT(s), pid);
|
||||
if (r < 0)
|
||||
log_unit_debug_errno(u, r, "Failed to watch main PID, ignoring: %m");
|
||||
}
|
||||
else
|
||||
(void) service_set_main_pid(s, pid);
|
||||
} else if (streq(key, "main-pid-known")) {
|
||||
int b;
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user