summaryrefslogtreecommitdiffstats
path: root/sys/nfsclient
diff options
context:
space:
mode:
authorpeter <peter@FreeBSD.org>1998-05-20 08:02:24 +0000
committerpeter <peter@FreeBSD.org>1998-05-20 08:02:24 +0000
commitbf07d95540db112811ffb3b7de9e6ca2432d24ae (patch)
tree4dca2d0d038c8d644edfd202e0a39bee37ecda27 /sys/nfsclient
parente207cd01f6bc4d6804a0ddefb33d2b7c7d9cb67d (diff)
downloadFreeBSD-src-bf07d95540db112811ffb3b7de9e6ca2432d24ae.zip
FreeBSD-src-bf07d95540db112811ffb3b7de9e6ca2432d24ae.tar.gz
A cleaner fix for PR#5102, clear nonsense flags at mount time rather than
in the core of nfs_bio.c at the 11th hour. PR: 5102
Diffstat (limited to 'sys/nfsclient')
-rw-r--r--sys/nfsclient/nfs_bio.c4
-rw-r--r--sys/nfsclient/nfs_vfsops.c6
2 files changed, 6 insertions, 4 deletions
diff --git a/sys/nfsclient/nfs_bio.c b/sys/nfsclient/nfs_bio.c
index 544ba32..d16bf1a 100644
--- a/sys/nfsclient/nfs_bio.c
+++ b/sys/nfsclient/nfs_bio.c
@@ -34,7 +34,7 @@
* SUCH DAMAGE.
*
* @(#)nfs_bio.c 8.9 (Berkeley) 3/30/95
- * $Id: nfs_bio.c,v 1.54 1998/03/28 16:05:05 steve Exp $
+ * $Id: nfs_bio.c,v 1.55 1998/05/19 07:11:22 peter Exp $
*/
@@ -1150,8 +1150,6 @@ nfs_doio(bp, cr, p)
case VDIR:
nfsstats.readdir_bios++;
uiop->uio_offset = ((u_quad_t)bp->b_lblkno) * NFS_DIRBLKSIZ;
- if (!(nmp->nm_flag & NFSMNT_NFSV3))
- nmp->nm_flag &= ~NFSMNT_RDIRPLUS;
if (nmp->nm_flag & NFSMNT_RDIRPLUS) {
error = nfs_readdirplusrpc(vp, uiop, cr);
if (error == NFSERR_NOTSUPP)
diff --git a/sys/nfsclient/nfs_vfsops.c b/sys/nfsclient/nfs_vfsops.c
index e6c7210..d6cdfe1 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.59 1998/05/19 07:11:25 peter Exp $
+ * $Id: nfs_vfsops.c,v 1.60 1998/05/20 07:59:21 peter Exp $
*/
#include <sys/param.h>
@@ -712,6 +712,10 @@ mountnfs(argp, mp, nam, pth, hst, vpp)
if (argp->sotype == SOCK_STREAM)
nmp->nm_flags &= ~NFSMNT_NOCONN;
+ /* Also clear RDIRPLUS if not NFSv3, it crashes some servers */
+ if ((argp->flags & NFSMNT_NFSV3) == 0)
+ nmp->nm_flag &= ~NFSMNT_RDIRPLUS;
+
if ((argp->flags & NFSMNT_TIMEO) && argp->timeo > 0) {
nmp->nm_timeo = (argp->timeo * NFS_HZ + 5) / 10;
if (nmp->nm_timeo < NFS_MINTIMEO)
OpenPOWER on IntegriCloud