diff --git a/common/SigUtil.cpp b/common/SigUtil.cpp index fc16839c9e9c..e8856a3d91a5 100644 --- a/common/SigUtil.cpp +++ b/common/SigUtil.cpp @@ -179,7 +179,7 @@ void requestShutdown() return std::make_pair(ret, WTERMSIG(status)); } } - else if (pid > 0) + else if (pid > 0 && ::kill(pid, 0) == 0) // Don't complain if the process is reaped already. { // Log errno if we had a child pid we expected to reap. LOG_WRN("Failed to reap child process " << pid << " (" << Util::symbolicErrno(errno)