aboutsummaryrefslogtreecommitdiff
path: root/sys/kern/vfs_mount.c
diff options
context:
space:
mode:
authorCraig Rodrigues <rodrigc@FreeBSD.org>2008-08-23 01:16:09 +0000
committerCraig Rodrigues <rodrigc@FreeBSD.org>2008-08-23 01:16:09 +0000
commitd5bdb2f68db6b6f668932a4207ffac48283d8cea (patch)
tree8db79e6fecc18aaec8e5b567b3207e3ddba6be03 /sys/kern/vfs_mount.c
parent6205924afded89564c2a91dbb9d6dd3c36a47b02 (diff)
downloadsrc-d5bdb2f68db6b6f668932a4207ffac48283d8cea.tar.gz
src-d5bdb2f68db6b6f668932a4207ffac48283d8cea.zip
In nmount(), when we see the "force" option,
set the MNT_FORCE flag, but do not persist "force" in the options list, since it is a command, not a persistent property of a mount. Similarly, when we see "reload", set MNT_RELOAD, but delete "reload" from the options list. MFC after: 1 week
Notes
Notes: svn path=/head/; revision=182025
Diffstat (limited to 'sys/kern/vfs_mount.c')
-rw-r--r--sys/kern/vfs_mount.c8
1 files changed, 7 insertions, 1 deletions
diff --git a/sys/kern/vfs_mount.c b/sys/kern/vfs_mount.c
index 906ea18ff50a..ebee84b10ff1 100644
--- a/sys/kern/vfs_mount.c
+++ b/sys/kern/vfs_mount.c
@@ -640,8 +640,14 @@ vfs_donmount(struct thread *td, int fsflags, struct uio *fsoptions)
}
else if (strcmp(opt->name, "async") == 0)
fsflags |= MNT_ASYNC;
- else if (strcmp(opt->name, "force") == 0)
+ else if (strcmp(opt->name, "force") == 0) {
fsflags |= MNT_FORCE;
+ vfs_freeopt(optlist, opt);
+ }
+ else if (strcmp(opt->name, "reload") == 0) {
+ fsflags |= MNT_RELOAD;
+ vfs_freeopt(optlist, opt);
+ }
else if (strcmp(opt->name, "multilabel") == 0)
fsflags |= MNT_MULTILABEL;
else if (strcmp(opt->name, "noasync") == 0)