aboutsummaryrefslogtreecommitdiff
path: root/toys/other/chroot.c
diff options
context:
space:
mode:
Diffstat (limited to 'toys/other/chroot.c')
-rw-r--r--toys/other/chroot.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/toys/other/chroot.c b/toys/other/chroot.c
index 00fb4e7f..e82dd803 100644
--- a/toys/other/chroot.c
+++ b/toys/other/chroot.c
@@ -20,6 +20,6 @@ void chroot_main(void)
char *binsh[] = {"/bin/sh", "-i", 0};
if (chdir(*toys.optargs) || chroot(".")) perror_exit("%s", *toys.optargs);
- if (toys.optargs[1]) xexec_optargs(1);
+ if (toys.optargs[1]) xexec(toys.optargs+1);
else xexec(binsh);
}