mirror of
https://github.com/systemd/systemd.git
synced 2024-12-25 01:34:28 +03:00
service: when reading pid file make sure to watch the pid read
This commit is contained in:
parent
4f320e4d73
commit
16f6025e70
@ -845,6 +845,10 @@ static int service_load_pid_file(Service *s) {
|
|||||||
return -ESRCH;
|
return -ESRCH;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
if ((r = unit_watch_pid(UNIT(s), (pid_t) p)) < 0)
|
||||||
|
/* FIXME: we need to do something here */
|
||||||
|
return r;
|
||||||
|
|
||||||
s->main_pid = (pid_t) p;
|
s->main_pid = (pid_t) p;
|
||||||
s->main_pid_known = true;
|
s->main_pid_known = true;
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user