diff options
author | Daniel Rosenberg <drosen@google.com> | 2018-10-15 15:10:52 -0700 |
---|---|---|
committer | Greg Kroah-Hartman <gregkh@linuxfoundation.org> | 2018-10-18 09:13:20 +0200 |
commit | a295ff4bff4c41823e7b33078d8164805cebdda4 (patch) | |
tree | 7f4de4e0dbcbf604ae06da8c533027e555b179b2 /fs/ext4 | |
parent | 5b48d1a8ccaddc78dd916435ec1a00c67e83628e (diff) |
ext4: Fix error code in ext4_xattr_set_entry()
ext4_xattr_set_entry should return EFSCORRUPTED instead of EIO
for corrupted xattr entries.
Fixes b469713e0c0c ("ext4: add corruption check in ext4_xattr_set_entry()")
Signed-off-by: Daniel Rosenberg <drosen@google.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Diffstat (limited to 'fs/ext4')
-rw-r--r-- | fs/ext4/xattr.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/fs/ext4/xattr.c b/fs/ext4/xattr.c index c10180d0b018..7d6da09e637b 100644 --- a/fs/ext4/xattr.c +++ b/fs/ext4/xattr.c @@ -657,7 +657,7 @@ ext4_xattr_set_entry(struct ext4_xattr_info *i, struct ext4_xattr_search *s, next = EXT4_XATTR_NEXT(last); if ((void *)next >= s->end) { EXT4_ERROR_INODE(inode, "corrupted xattr entries"); - return -EIO; + return -EFSCORRUPTED; } if (last->e_value_size) { size_t offs = le16_to_cpu(last->e_value_offs); |