Skip to content

Commit

Permalink
ext4: bail out of ext4_xattr_ibody_get() fails for any reason
Browse files Browse the repository at this point in the history
In ext4_update_inline_data(), if ext4_xattr_ibody_get() fails for any
reason, it's best if we just fail as opposed to stumbling on,
especially if the failure is EFSCORRUPTED.

Cc: [email protected]
Signed-off-by: Theodore Ts'o <[email protected]>
  • Loading branch information
tytso committed May 13, 2023
1 parent 2220eaf commit 2a534e1
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion fs/ext4/inline.c
Original file line number Diff line number Diff line change
Expand Up @@ -360,7 +360,7 @@ static int ext4_update_inline_data(handle_t *handle, struct inode *inode,

error = ext4_xattr_ibody_get(inode, i.name_index, i.name,
value, len);
if (error == -ENODATA)
if (error < 0)
goto out;

BUFFER_TRACE(is.iloc.bh, "get_write_access");
Expand Down

0 comments on commit 2a534e1

Please sign in to comment.