diff mbox

[v3,16/30] debugfs: make lsdel command support inline data

Message ID 1386323897-2354-17-git-send-email-wenqing.lz@taobao.com
State Superseded, archived
Headers show

Commit Message

Zheng Liu Dec. 6, 2013, 9:58 a.m. UTC
From: Zheng Liu <wenqing.lz@taobao.com>

After checking inline data in ext2fs_inode_have_valid_blocks2() we won't
traverse the block in do_lsdel() function.  But if an inode has inline
data we also need to report it.

Signed-off-by: Theodore Ts'o <tytso@mit.edu>
Signed-off-by: Zheng Liu <wenqing.lz@taobao.com>
---
 debugfs/lsdel.c |    3 ++-
 1 file changed, 2 insertions(+), 1 deletion(-)
diff mbox

Patch

diff --git a/debugfs/lsdel.c b/debugfs/lsdel.c
index ba84611..b61951f 100644
--- a/debugfs/lsdel.c
+++ b/debugfs/lsdel.c
@@ -152,7 +152,8 @@  void do_lsdel(int argc, char **argv)
 				goto next;
 			}
 		}
-		if (lsd.free_blocks && !lsd.bad_blocks) {
+		if (lsd.free_blocks && !lsd.bad_blocks ||
+		    inode.i_flags & EXT4_INLINE_DATA_FL) {
 			if (num_delarray >= max_delarray) {
 				max_delarray += 50;
 				delarray = realloc(delarray,