ext2fs(4): Fix a number of broken flag checks

Introduced in r319071.

Reported by:	Coverity
CIDs:		1375847, 1375848, 1375849
Sponsored by:	Dell EMC Isilon
This commit is contained in:
cem 2017-06-03 22:30:30 +00:00
parent dd1ca3606d
commit bbbfdaced9

View File

@ -276,7 +276,7 @@ ext2_getacl(struct vop_getacl_args *ap)
{
if (((ap->a_vp->v_mount->mnt_flag & MNT_ACLS) == 0) ||
((ap->a_vp->v_mount->mnt_flag & MNT_NFS4ACLS) == 1))
((ap->a_vp->v_mount->mnt_flag & MNT_NFS4ACLS) != 0))
return (EOPNOTSUPP);
if (ap->a_type == ACL_TYPE_NFS4)
@ -473,7 +473,7 @@ int
ext2_setacl(struct vop_setacl_args *ap)
{
if (((ap->a_vp->v_mount->mnt_flag & MNT_ACLS) == 0) ||
((ap->a_vp->v_mount->mnt_flag & MNT_NFS4ACLS) == 1))
((ap->a_vp->v_mount->mnt_flag & MNT_NFS4ACLS) != 0))
return (EOPNOTSUPP);
if (ap->a_type == ACL_TYPE_NFS4)
@ -490,7 +490,7 @@ ext2_aclcheck(struct vop_aclcheck_args *ap)
{
if (((ap->a_vp->v_mount->mnt_flag & MNT_ACLS) == 0) ||
((ap->a_vp->v_mount->mnt_flag & MNT_NFS4ACLS) == 1))
((ap->a_vp->v_mount->mnt_flag & MNT_NFS4ACLS) != 0))
return (EOPNOTSUPP);
if (ap->a_type == ACL_TYPE_NFS4)