[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <20140805010543.2611.86125.stgit@birch.djwong.org>
Date: Mon, 04 Aug 2014 18:05:43 -0700
From: "Darrick J. Wong" <darrick.wong@...cle.com>
To: tytso@....edu, darrick.wong@...cle.com
Cc: linux-ext4@...r.kernel.org
Subject: [PATCH 07/21] libext2fs: remove EA when inline data is less than 60
bytes
If we write less than 60 bytes of inline data, remove the EA.
Signed-off-by: Darrick J. Wong <darrick.wong@...cle.com>
---
lib/ext2fs/inline_data.c | 3 +++
1 file changed, 3 insertions(+)
diff --git a/lib/ext2fs/inline_data.c b/lib/ext2fs/inline_data.c
index b9bda50..8a71d18 100644
--- a/lib/ext2fs/inline_data.c
+++ b/lib/ext2fs/inline_data.c
@@ -557,6 +557,9 @@ errcode_t ext2fs_inline_data_set(ext2_filsys fs, ext2_ino_t ino,
}
if (size <= EXT4_MIN_INLINE_DATA_SIZE) {
+ retval = ext2fs_inline_data_ea_remove(fs, ino);
+ if (retval)
+ return retval;
memcpy((void *)inode->i_block, buf, size);
return ext2fs_write_inode(fs, ino, inode);
}
--
To unsubscribe from this list: send the line "unsubscribe linux-ext4" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Powered by blists - more mailing lists