X-Git-Url: https://git.decadent.org.uk/gitweb/?a=blobdiff_plain;ds=sidebyside;f=utils%2Fmount%2Fmount.c;h=4698d85fd98f6f9cd30c00f8644dff26ceb41082;hb=33f60147abb70ce36017c58366b0a1710453bb00;hp=487c0a62bc20f5d7edf02a72334423c1ee30702a;hpb=6facb22402a0bd8cd49be2ed1a0856b24fef42f4;p=nfs-utils.git diff --git a/utils/mount/mount.c b/utils/mount/mount.c index 487c0a6..4698d85 100644 --- a/utils/mount/mount.c +++ b/utils/mount/mount.c @@ -99,11 +99,9 @@ static const struct opt_map opt_map[] = { { "rbind", 0, 0, MS_BIND|MS_REC }, /* Idem, plus mounted subtrees */ { "auto", 0, 0, MS_DUMMY }, /* Can be mounted using -a */ { "noauto", 0, 0, MS_DUMMY }, /* Can only be mounted explicitly */ - { "users", 1, 0, MS_USERS|MS_NOEXEC|MS_NOSUID|MS_NODEV }, - /* Allow ordinary user to mount */ + { "users", 1, 0, MS_USERS }, /* Allow ordinary user to mount */ { "nousers", 0, 1, MS_DUMMY }, /* Forbid ordinary user to mount */ - { "user", 1, 0, MS_USER|MS_NOEXEC|MS_NOSUID|MS_NODEV }, - /* Allow ordinary user to mount */ + { "user", 1, 0, MS_USER }, /* Allow ordinary user to mount */ { "nouser", 0, 1, MS_DUMMY }, /* Forbid ordinary user to mount */ { "owner", 0, 0, MS_DUMMY }, /* Let the owner of the device mount */ { "noowner", 0, 0, MS_DUMMY }, /* Device owner has no special privs */ @@ -262,7 +260,7 @@ static void parse_opts (const char *options, int *flags, char **extra_opts) if (options != NULL) { char *opts = xstrdup(options); char *opt, *p; - int len = strlen(opts); + int len = strlen(opts) + 1; /* include room for a null */ int open_quote = 0; *extra_opts = xmalloc(len); @@ -437,7 +435,7 @@ int main(int argc, char *argv[]) exit(1); } - if (strcmp(progname, "mount.nfsv4") == 0) + if (strcmp(progname, "mount.nfs4") == 0) nfs_mount_vers = 4; if (uid != 0) {