From: Denis Vlasenko Date: Tue, 21 Apr 2009 00:29:17 +0000 (-0000) Subject: switch_root: print errno on failure X-Git-Tag: 1_15_0~302 X-Git-Url: https://git.librecmc.org/?a=commitdiff_plain;h=0ad82344743e990e6985a8ee1b39a85fc4126084;p=oweals%2Fbusybox.git switch_root: print errno on failure --- diff --git a/util-linux/switch_root.c b/util-linux/switch_root.c index 21cc99229..08aa72597 100644 --- a/util-linux/switch_root.c +++ b/util-linux/switch_root.c @@ -97,7 +97,7 @@ int switch_root_main(int argc UNUSED_PARAM, char **argv) // Overmount / with newdir and chroot into it. The chdir is needed to // recalculate "." and ".." links. if (mount(".", "/", NULL, MS_MOVE, NULL)) - bb_error_msg_and_die("error moving root"); + bb_perror_msg_and_die("error moving root"); xchroot("."); xchdir("/");