From cd25cce98f5cc930202212c3c9c13605c09698b4 Mon Sep 17 00:00:00 2001 From: Lennart Poettering Date: Tue, 29 Mar 2011 23:31:38 +0200 Subject: exec: drop process group kill mode since it has little use and confuses the user --- src/swap.c | 6 ++---- 1 file changed, 2 insertions(+), 4 deletions(-) (limited to 'src/swap.c') diff --git a/src/swap.c b/src/swap.c index 035efbaf4b..66bf5c2bfb 100644 --- a/src/swap.c +++ b/src/swap.c @@ -661,9 +661,7 @@ static void swap_enter_signal(Swap *s, SwapState state, bool success) { state == SWAP_DEACTIVATING_SIGTERM) ? s->exec_context.kill_signal : SIGKILL; if (s->control_pid > 0) { - if (kill_and_sigcont(s->exec_context.kill_mode == KILL_PROCESS_GROUP ? - -s->control_pid : - s->control_pid, sig) < 0 && errno != ESRCH) + if (kill_and_sigcont(s->control_pid, sig) < 0 && errno != ESRCH) log_warning("Failed to kill control process %li: %m", (long) s->control_pid); else @@ -1286,7 +1284,7 @@ static int swap_kill(Unit *u, KillWho who, KillMode mode, int signo, DBusError * } if (s->control_pid > 0) - if (kill(mode == KILL_PROCESS_GROUP ? -s->control_pid : s->control_pid, signo) < 0) + if (kill(s->control_pid, signo) < 0) r = -errno; if (mode == KILL_CONTROL_GROUP) { -- cgit v1.2.3-54-g00ecf