[PATCH] xfs: fix off-by-one error in xfs_attr3_rmt_verify
Jeff Liu
jeff.liu at oracle.com
Tue Jan 7 01:02:11 CST 2014
On 01/06 2014 22:38 PM, Mark Tinguely wrote:
> On 01/01/14 05:28, Jeff Liu wrote:
>> From: Jie Liu<jeff.liu at oracle.com>
>>
>> With CRC check is enabled, if trying to set an attributes value just
>> equal to the maximum size of XATTR_SIZE_MAX would cause the v3 remote
>> attr write verification procedure failure, which would yield the back
>> trace like below:
>>
>> <snip>
>> XFS (sda7): Internal error xfs_attr3_rmt_write_verify at line 191 of
>> file fs/xfs/xfs_attr_remote.c
>> <snip>
>> Call Trace:
<snip>
>>
>> Tests:
>> setfattr -n user.longxattr -v `perl -e 'print "A"x65536'` testfile
>>
>> This patch fix it to check the remote EA size is greater than the
>> XATTR_SIZE_MAX rather than more than or equal to it, because it's
>> valid if the specified EA value size is equal to the limitation as
>> per VFS setxattr interface.
>>
>> Signed-off-by: Jie Liu<jeff.liu at oracle.com>
>> ---
>
> Good catch. Are you making an edge case xfstest?
I plan to introduce a particular test case into generic subclass.
Thanks,
-Jeff
More information about the xfs
mailing list