summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--sys/fs/nfsclient/nfs_clvnops.c4
1 files changed, 3 insertions, 1 deletions
diff --git a/sys/fs/nfsclient/nfs_clvnops.c b/sys/fs/nfsclient/nfs_clvnops.c
index 73e5ed9..43774dd 100644
--- a/sys/fs/nfsclient/nfs_clvnops.c
+++ b/sys/fs/nfsclient/nfs_clvnops.c
@@ -767,7 +767,9 @@ nfs_close(struct vop_close_args *ap)
/*
* Get attributes so "change" is up to date.
*/
- if (error == 0 && nfscl_mustflush(vp) != 0) {
+ if (error == 0 && nfscl_mustflush(vp) != 0 &&
+ vp->v_type == VREG &&
+ (VFSTONFS(vp->v_mount)->nm_flag & NFSMNT_NOCTO) == 0) {
ret = nfsrpc_getattr(vp, cred, ap->a_td, &nfsva,
NULL);
if (!ret) {
OpenPOWER on IntegriCloud