Commit ad4a8ac4 authored by Eric Sandeen's avatar Eric Sandeen Committed by Nathan Scott

[XFS] Fix check for writeable file in xfs_ioc_space ioctl code

SGI-PV: 938905
SGI-Modid: xfs-linux:xfs-kern:195240a
Signed-off-by: default avatarEric Sandeen <sandeen@sgi.com>
Signed-off-by: default avatarNathan Scott <nathans@sgi.com>
parent 3bdbfb10
......@@ -982,7 +982,7 @@ xfs_ioc_space(
if (vp->v_inode.i_flags & (S_IMMUTABLE|S_APPEND))
return -XFS_ERROR(EPERM);
if (!(filp->f_flags & FMODE_WRITE))
if (!(filp->f_mode & FMODE_WRITE))
return -XFS_ERROR(EBADF);
if (vp->v_type != VREG)
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment