[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-Id: <20181016170540.127292570@linuxfoundation.org>
Date: Tue, 16 Oct 2018 19:09:11 +0200
From: Greg Kroah-Hartman <gregkh@...uxfoundation.org>
To: linux-kernel@...r.kernel.org, stable@...r.kernel.org
Cc: Greg Kroah-Hartman <gregkh@...uxfoundation.org>,
Daniel Rosenberg <drosen@...gle.com>
Subject: [PATCH 4.9 14/71] ext4: Fix error code in ext4_xattr_set_entry()
4.9-stable review patch. If anyone has any objections, please let me know.
------------------
From: Daniel Rosenberg <drosen@...gle.com>
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@...gle.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@...uxfoundation.org>
---
Apply to 4.9
fs/ext4/xattr.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
--- a/fs/ext4/xattr.c
+++ b/fs/ext4/xattr.c
@@ -657,7 +657,7 @@ ext4_xattr_set_entry(struct ext4_xattr_i
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);
Powered by blists - more mailing lists