about summary refs log tree commit diff
path: root/src/libutil/util.cc
diff options
context:
space:
mode:
Diffstat (limited to 'src/libutil/util.cc')
-rw-r--r--src/libutil/util.cc10
1 files changed, 5 insertions, 5 deletions
diff --git a/src/libutil/util.cc b/src/libutil/util.cc
index ce54350d7684..2998506b5821 100644
--- a/src/libutil/util.cc
+++ b/src/libutil/util.cc
@@ -724,20 +724,20 @@ void Pid::kill(bool quiet)
     if (pid == -1 || pid == 0) return;
 
     if (!quiet)
-        printMsg(lvlError, format("killing process %1%") % pid);
+        printError(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
        process group (which hopefully includes *all* its children). */
     if (::kill(separatePG ? -pid : pid, killSignal) != 0)
-        printMsg(lvlError, (SysError(format("killing process %1%") % pid).msg()));
+        printError((SysError(format("killing process %1%") % pid).msg()));
 
     /* Wait until the child dies, disregarding the exit status. */
     int status;
     while (waitpid(pid, &status, 0) == -1) {
         checkInterrupt();
         if (errno != EINTR) {
-            printMsg(lvlError,
+            printError(
                 (SysError(format("waiting for process %1%") % pid).msg()));
             break;
         }
@@ -1125,7 +1125,7 @@ void ignoreException()
     try {
         throw;
     } catch (std::exception & e) {
-        printMsg(lvlError, format("error (ignored): %1%") % e.what());
+        printError(format("error (ignored): %1%") % e.what());
     }
 }
 
@@ -1228,7 +1228,7 @@ void callFailure(const std::function<void(std::exception_ptr exc)> & failure, st
     try {
         failure(exc);
     } catch (std::exception & e) {
-        printMsg(lvlError, format("uncaught exception: %s") % e.what());
+        printError(format("uncaught exception: %s") % e.what());
         abort();
     }
 }