svn commit: r272118 - stable/10/contrib/smbfs/mount_smbfs
Edward Tomasz Napierala
trasz at FreeBSD.org
Thu Sep 25 17:47:27 UTC 2014
Author: trasz
Date: Thu Sep 25 17:47:26 2014
New Revision: 272118
URL: http://svnweb.freebsd.org/changeset/base/272118
Log:
MFC r271258:
Make mount_smbfs(8) preserve the "automounted" mount flag.
The issue here is that we have to pass this flag as a string,
in iov, because it doesn't fit in mntflags, which is an int.
Approved by: re (gjb)
Sponsored by: The FreeBSD Foundation
Modified:
stable/10/contrib/smbfs/mount_smbfs/mount_smbfs.c
Directory Properties:
stable/10/ (props changed)
Modified: stable/10/contrib/smbfs/mount_smbfs/mount_smbfs.c
==============================================================================
--- stable/10/contrib/smbfs/mount_smbfs/mount_smbfs.c Thu Sep 25 17:38:42 2014 (r272117)
+++ stable/10/contrib/smbfs/mount_smbfs/mount_smbfs.c Thu Sep 25 17:47:26 2014 (r272118)
@@ -81,7 +81,7 @@ main(int argc, char *argv[])
#else
struct xvfsconf vfc;
#endif
- char *next;
+ char *next, *p, *val;
int opt, error, mntflags, caseopt, fd;
uid_t uid;
gid_t gid;
@@ -194,6 +194,13 @@ main(int argc, char *argv[])
};
case 'o':
getmntopts(optarg, mopts, &mntflags, 0);
+ p = strchr(optarg, '=');
+ val = NULL;
+ if (p != NULL) {
+ *p = '\0';
+ val = p + 1;
+ }
+ build_iovec(&iov, &iovlen, optarg, val, (size_t)-1);
break;
case 'c':
switch (optarg[0]) {
More information about the svn-src-stable-10
mailing list