diff options
author | dfr <dfr@FreeBSD.org> | 1997-06-03 17:22:47 +0000 |
---|---|---|
committer | dfr <dfr@FreeBSD.org> | 1997-06-03 17:22:47 +0000 |
commit | 99eae7b7b1d0dfe2463f468406efaea5f7258df8 (patch) | |
tree | ac6a203d84dfbdf93133d0f9bb62f4da2d4b8804 /sys/nfsclient/nfs_vfsops.c | |
parent | a70561d506231c0740e4c09afc2f53bc95a62073 (diff) | |
download | FreeBSD-src-99eae7b7b1d0dfe2463f468406efaea5f7258df8.zip FreeBSD-src-99eae7b7b1d0dfe2463f468406efaea5f7258df8.tar.gz |
Various fixes from NetBSD:
Use u_int for rpc procedure numbers.
Some fixes to NQNFS.
A rare NULL pointer dereference.
Ignore NFSMNT_NOCONN for TCP mounts.
Obtained from: NetBSD
Diffstat (limited to 'sys/nfsclient/nfs_vfsops.c')
-rw-r--r-- | sys/nfsclient/nfs_vfsops.c | 9 |
1 files changed, 8 insertions, 1 deletions
diff --git a/sys/nfsclient/nfs_vfsops.c b/sys/nfsclient/nfs_vfsops.c index 207b129..9bcc0f7 100644 --- a/sys/nfsclient/nfs_vfsops.c +++ b/sys/nfsclient/nfs_vfsops.c @@ -34,7 +34,7 @@ * SUCH DAMAGE. * * @(#)nfs_vfsops.c 8.12 (Berkeley) 5/20/95 - * $Id: nfs_vfsops.c,v 1.41 1997/05/11 18:05:38 tegge Exp $ + * $Id: nfs_vfsops.c,v 1.42 1997/05/12 19:02:56 tegge Exp $ */ #include <sys/param.h> @@ -706,6 +706,13 @@ mountnfs(argp, mp, nam, pth, hst, vpp) bcopy(pth, mp->mnt_stat.f_mntonname, MNAMELEN); nmp->nm_nam = nam; + /* + * Silently clear NFSMNT_NOCONN if it's a TCP mount, it makes + * no sense in that context. + */ + if (argp->sotype == SOCK_STREAM) + argp->flags &= ~NFSMNT_NOCONN; + if ((argp->flags & NFSMNT_TIMEO) && argp->timeo > 0) { nmp->nm_timeo = (argp->timeo * NFS_HZ + 5) / 10; if (nmp->nm_timeo < NFS_MINTIMEO) |