mirror of
git://sourceware.org/git/lvm2.git
synced 2025-01-02 01:18:26 +03:00
Do exit if LISTEN_PID environment variable not correct during systemd handover.
This commit is contained in:
parent
fad6a65f3c
commit
761407217a
@ -177,7 +177,7 @@ static int _systemd_handover(struct daemon_state *ds)
|
|||||||
env_pid = strtoul(e, &p, 10);
|
env_pid = strtoul(e, &p, 10);
|
||||||
if (errno || !p || *p || env_pid <= 0 ||
|
if (errno || !p || *p || env_pid <= 0 ||
|
||||||
getpid() != (pid_t) env_pid)
|
getpid() != (pid_t) env_pid)
|
||||||
;
|
goto out;
|
||||||
|
|
||||||
/* LISTEN_FDS must be 1 and the fd must be a socket! */
|
/* LISTEN_FDS must be 1 and the fd must be a socket! */
|
||||||
if (!(e = getenv(SD_LISTEN_FDS_ENV_VAR_NAME)))
|
if (!(e = getenv(SD_LISTEN_FDS_ENV_VAR_NAME)))
|
||||||
|
Loading…
Reference in New Issue
Block a user