diff options
Diffstat (limited to 'coreutils/chroot.c')
-rw-r--r-- | coreutils/chroot.c | 6 |
1 files changed, 2 insertions, 4 deletions
diff --git a/coreutils/chroot.c b/coreutils/chroot.c index 1c64e08a9..95aed3d17 100644 --- a/coreutils/chroot.c +++ b/coreutils/chroot.c | |||
@@ -47,8 +47,7 @@ int chroot_main(int argc, char **argv) | |||
47 | argv++; | 47 | argv++; |
48 | 48 | ||
49 | if (chroot(*argv) || (chdir("/"))) { | 49 | if (chroot(*argv) || (chdir("/"))) { |
50 | fatalError("chroot: cannot change root directory to %s: %s\n", | 50 | fatalError("cannot change root directory to %s: %s\n", *argv, strerror(errno)); |
51 | *argv, strerror(errno)); | ||
52 | } | 51 | } |
53 | 52 | ||
54 | argc--; | 53 | argc--; |
@@ -62,8 +61,7 @@ int chroot_main(int argc, char **argv) | |||
62 | prog = "/bin/sh"; | 61 | prog = "/bin/sh"; |
63 | execlp(prog, prog, NULL); | 62 | execlp(prog, prog, NULL); |
64 | } | 63 | } |
65 | fatalError("chroot: cannot execute %s: %s\n", | 64 | fatalError("cannot execute %s: %s\n", prog, strerror(errno)); |
66 | prog, strerror(errno)); | ||
67 | 65 | ||
68 | } | 66 | } |
69 | 67 | ||