Allow trailing slashes for MNT_UPDATE case (mount -u), too.

PR:		bin/59144
Submitted by:	Stefan Farfeleder <stefan@fafoe.narf.at>
This commit is contained in:
Eric Anholt 2004-01-07 05:37:56 +00:00
parent 624a58b6e6
commit 01a9bce5ee
Notes: svn2git 2020-12-20 02:59:44 +00:00
svn path=/head/; revision=124201

View File

@ -234,6 +234,7 @@ main(argc, argv)
if (vfslist != NULL)
usage();
rmslashes(*argv, *argv);
if (init_flags & MNT_UPDATE) {
mntfromname = NULL;
have_fstab = 0;
@ -272,7 +273,6 @@ main(argc, argv)
mntbuf->f_mntonname, init_flags, options, 0);
break;
}
rmslashes(*argv, *argv);
if ((fs = getfsfile(*argv)) == NULL &&
(fs = getfsspec(*argv)) == NULL)
errx(1, "%s: unknown special file or file system",