summaryrefslogtreecommitdiff
path: root/src/chroot.c
diff options
context:
space:
mode:
Diffstat (limited to 'src/chroot.c')
-rw-r--r--src/chroot.c5
1 files changed, 3 insertions, 2 deletions
diff --git a/src/chroot.c b/src/chroot.c
index 1eb443c24..6d3fddf77 100644
--- a/src/chroot.c
+++ b/src/chroot.c
@@ -1,5 +1,5 @@
/* chroot -- run command or shell with special root directory
- Copyright (C) 95, 96, 1997, 1999-2004, 2007-2008
+ Copyright (C) 95, 96, 1997, 1999-2004, 2007-2009
Free Software Foundation, Inc.
This program is free software: you can redistribute it and/or modify
@@ -83,7 +83,8 @@ main (int argc, char **argv)
}
if (chroot (argv[optind]) != 0)
- error (EXIT_FAILURE, errno, _("cannot change root directory to %s"), argv[1]);
+ error (EXIT_FAILURE, errno, _("cannot change root directory to %s"),
+ argv[optind]);
if (chdir ("/"))
error (EXIT_FAILURE, errno, _("cannot chdir to root directory"));