summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorPeter Korsgaard2011-02-21 17:52:13 +0100
committerDenys Vlasenko2011-02-26 19:02:36 +0100
commit301fe50ca2576291a427de46ca6ed64d4949713e (patch)
treea3f082ec6ae5291d38487dc6a76e681ef7a892c8
parent945fd173e9888185d68fecfb060fdfff98900ac4 (diff)
downloadbusybox-301fe50ca2576291a427de46ca6ed64d4949713e.zip
busybox-301fe50ca2576291a427de46ca6ed64d4949713e.tar.gz
mount: ignore unknown mount options when remounting NFS mounts
Don't fail on unknown nfs mount options. The kernel automatically adds a few mount options that we don't currently handle, like: sec=null|sys|krb5.. mountaddr=<ip> mountproto=tcp|udp local_lock=none|all|flock|posix Which causes a simple mount -o remount,rw <mountpoint> to fail. Signed-off-by: Peter Korsgaard <jacmet@sunsite.dk> Signed-off-by: Denys Vlasenko <vda.linux@googlemail.com>
-rw-r--r--util-linux/mount.c3
1 files changed, 3 insertions, 0 deletions
diff --git a/util-linux/mount.c b/util-linux/mount.c
index bc52850..0baa74c 100644
--- a/util-linux/mount.c
+++ b/util-linux/mount.c
@@ -1129,6 +1129,9 @@ static NOINLINE int nfsmount(struct mntent *mp, long vfsflags, char *filteropts)
continue;
case 20: // "addr" - ignore
continue;
+ case -1: // unknown
+ if (vfsflags & MS_REMOUNT)
+ continue;
}
val = xatoi_positive(opteq);