(child_error): Use strsignal.
authorRoland McGrath <roland@redhat.com>
Wed, 22 Feb 1995 03:17:54 +0000 (03:17 +0000)
committerRoland McGrath <roland@redhat.com>
Wed, 22 Feb 1995 03:17:54 +0000 (03:17 +0000)
job.c

diff --git a/job.c b/job.c
index 8640b27f09760d6963bcfca3a0b9b0bc856210e1..a977fb5a7cbdb7d586f584b1c74ef7c916c4b4cc 100644 (file)
--- a/job.c
+++ b/job.c
@@ -174,14 +174,9 @@ child_error (target_name, exit_code, exit_sig, coredump, ignored)
           "*** [%s] Error %d",
           target_name, exit_code);
   else
-    {
-      char *coredump_string = coredump ? " (core dumped)" : "";
-      if (exit_sig > 0 && exit_sig < NSIG)
-       error ("*** [%s] %s%s",
-              target_name, sys_siglist[exit_sig], coredump_string);
-      else
-       error ("*** [%s] Signal %d%s", target_name, exit_sig, coredump_string);
-    }
+    error ("*** [%s] %s%s",
+          target_name, strsignal (exit_sig),
+          coredump ? " (core dumped)" : "");
 }
 \f
 static unsigned int dead_children = 0;