aboutsummaryrefslogtreecommitdiff
path: root/init/init.c
diff options
context:
space:
mode:
Diffstat (limited to 'init/init.c')
-rw-r--r--init/init.c7
1 files changed, 3 insertions, 4 deletions
diff --git a/init/init.c b/init/init.c
index 3b0a66a24..edbd90bfe 100644
--- a/init/init.c
+++ b/init/init.c
@@ -660,8 +660,7 @@ static pid_t run(struct init_action *a)
execve(cmdpath, cmd, environment);
/* We're still here? Some error happened. */
- message(LOG | CONSOLE, "\rBummer, could not run '%s': %s\n", cmdpath,
- strerror(errno));
+ message(LOG | CONSOLE, "\rBummer, could not run '%s': %m\n", cmdpath);
_exit(-1);
}
sigprocmask(SIG_SETMASK, &omask, NULL);
@@ -785,8 +784,8 @@ static void exec_signal(int sig)
message(CONSOLE | LOG, "\rTrying to re-exec %s\n", a->command);
execl(a->command, a->command, NULL);
- message(CONSOLE | LOG, "\rexec of '%s' failed: %s\n",
- a->command, strerror(errno));
+ message(CONSOLE | LOG, "\rexec of '%s' failed: %m\n",
+ a->command);
sync();
sleep(2);
init_reboot(RB_HALT_SYSTEM);