chiark / gitweb /
Fix check for signal in set (#5416)
[elogind.git] / src / basic / process-util.c
index a5f355c10d567e87de29d9208e4c6e30f94e3481..8ced76a897c2375b4af9ac4d5acfa499ce9bc63b 100644 (file)
@@ -708,7 +708,7 @@ int kill_and_sigcont(pid_t pid, int sig) {
 
         /* If this worked, also send SIGCONT, unless we already just sent a SIGCONT, or SIGKILL was sent which isn't
          * affected by a process being suspended anyway. */
-        if (r >= 0 && !IN_SET(SIGCONT, SIGKILL))
+        if (r >= 0 && !IN_SET(sig, SIGCONT, SIGKILL))
                 (void) kill(pid, SIGCONT);
 
         return r;