Signed-off-by: Roel Kluin <roel.kluin@gmail.com>
@@ -1300,6 +1300,8 @@ int ext4_expand_extra_isize_ea(struct inode *inode, int new_extra_isize,
/* Remove the chosen entry from the inode */
error = ext4_xattr_ibody_set(handle, inode, &i, is);
+ if (error)
+ goto cleanup;
entry = IFIRST(header);
if (entry_size + EXT4_XATTR_SIZE(size) >= new_extra_isize)