diff options
Diffstat (limited to 'nix/libutil')
-rw-r--r-- | nix/libutil/util.cc | 5 | ||||
-rw-r--r-- | nix/libutil/util.hh | 2 |
2 files changed, 4 insertions, 3 deletions
diff --git a/nix/libutil/util.cc b/nix/libutil/util.cc index b79212018b..22f49f76d5 100644 --- a/nix/libutil/util.cc +++ b/nix/libutil/util.cc @@ -740,11 +740,12 @@ Pid::operator pid_t() } -void Pid::kill() +void Pid::kill(bool quiet) { if (pid == -1 || pid == 0) return; - printMsg(lvlError, format("killing process %1%") % pid); + if (!quiet) + printMsg(lvlError, format("killing process %1%") % pid); /* Send the requested signal to the child. If it has its own process group, send the signal to every process in the child diff --git a/nix/libutil/util.hh b/nix/libutil/util.hh index cf513c008e..7e538ea033 100644 --- a/nix/libutil/util.hh +++ b/nix/libutil/util.hh @@ -253,7 +253,7 @@ public: ~Pid(); void operator =(pid_t pid); operator pid_t(); - void kill(); + void kill(bool quiet = false); int wait(bool block); void setSeparatePG(bool separatePG); void setKillSignal(int signal); |