Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit b6827160 authored by Ira Weiny's avatar Ira Weiny Committed by Darrick J. Wong
Browse files

fs/xfs: Fix return code of xfs_break_leased_layouts()



The parens used in the while loop would result in error being assigned
the value 1 rather than the intended errno value.

This is required to return -ETXTBSY from follow on break_layout()
changes.

Signed-off-by: default avatarIra Weiny <ira.weiny@intel.com>
Reviewed-by: default avatarDarrick J. Wong <darrick.wong@oracle.com>
Signed-off-by: default avatarDarrick J. Wong <darrick.wong@oracle.com>
parent 5d888b48
Loading
Loading
Loading
Loading
+1 −1
Original line number Diff line number Diff line
@@ -32,7 +32,7 @@ xfs_break_leased_layouts(
	struct xfs_inode	*ip = XFS_I(inode);
	int			error;

	while ((error = break_layout(inode, false) == -EWOULDBLOCK)) {
	while ((error = break_layout(inode, false)) == -EWOULDBLOCK) {
		xfs_iunlock(ip, *iolock);
		*did_unlock = true;
		error = break_layout(inode, true);