nfscl: Clean up the code by removing vfs_flags() macro

The vfs_flags() macro was used to make the code compatible
with Mac OSX, for the Mac OSX port.
For FreeBSD, this macro just obscured the code, so
remove it to clean up the code.

This commit should not result in a semantics change.
This commit is contained in:
Rick Macklem 2022-06-20 13:23:04 -07:00
parent 164491fb03
commit 0586a12904
2 changed files with 1 additions and 2 deletions

View File

@ -36,7 +36,6 @@
* Darwin8 and hopefully subsequent releases from Apple.)
*/
typedef struct mount * mount_t;
#define vfs_flags(m) ((m)->mnt_flag)
typedef struct vnode * vnode_t;
#define vnode_vtype(v) ((v)->v_type)

View File

@ -438,7 +438,7 @@ nfsrvd_setattr(struct nfsrv_descript *nd, __unused int isdgram,
if (!nd->nd_repstat) {
if (NFSVNO_NOTSETSIZE(&nva)) {
if (NFSVNO_EXRDONLY(exp) ||
(vfs_flags(vp->v_mount) & MNT_RDONLY))
(vp->v_mount->mnt_flag & MNT_RDONLY))
nd->nd_repstat = EROFS;
} else {
if (vnode_vtype(vp) != VREG)