From 7af8e4ee2ad1ffee55be45206515038a3c581c65 Mon Sep 17 00:00:00 2001 From: Gui Hecheng Date: Thu, 28 Nov 2013 13:32:50 +0800 Subject: btrfs-progs: skip chunk recover works when check chunks successfully If no chunks need to be recovered, skip the recover works, meanwhile the user won't be annoyed by the "ask_user". Signed-off-by: Gui Hecheng Signed-off-by: David Sterba Signed-off-by: Chris Mason --- chunk-recover.c | 3 +++ 1 file changed, 3 insertions(+) (limited to 'chunk-recover.c') diff --git a/chunk-recover.c b/chunk-recover.c index ae0d318c..45d6eae1 100644 --- a/chunk-recover.c +++ b/chunk-recover.c @@ -1685,6 +1685,9 @@ int btrfs_recover_chunk_tree(char *path, int verbose, int yes) * droppped from the fs. Don't deal with them now, we will * check it after the fs is opened. */ + } else { + fprintf(stderr, "Check chunks successfully with no orphans\n"); + goto fail_rc; } root = open_ctree_with_broken_chunk(&rc); -- cgit v1.2.3