From 33c5b695d265b115b6ff96bbc33152feb4e69473 Mon Sep 17 00:00:00 2001 From: tanyifeng Date: Tue, 12 Feb 2019 14:00:47 +0800 Subject: [PATCH 058/138] do not check ppid when set death signal ppid will not be 0 if we shared host pid Signed-off-by: tanyifeng Signed-off-by: LiFeng --- src/lxc/utils.c | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/src/lxc/utils.c b/src/lxc/utils.c index 9a50fce..0aa87aa 100644 --- a/src/lxc/utils.c +++ b/src/lxc/utils.c @@ -1722,12 +1722,13 @@ int lxc_set_death_signal(int signal, pid_t parent) prctl_arg(0), prctl_arg(0)); /* Check whether we have been orphaned. */ - ppid = (pid_t)syscall(SYS_getppid); + /* isulad: delete this check, ppid will not be 0 if we shared host pid */ + /*ppid = (pid_t)syscall(SYS_getppid); if (ppid != parent) { ret = raise(SIGKILL); if (ret < 0) return -1; - } + }*/ if (ret < 0) return -1; -- 1.8.3.1