Btrfs-progs: don't try to repair reloc roots
authorJosef Bacik <jbacik@fb.com>
Thu, 15 Jan 2015 22:11:41 +0000 (17:11 -0500)
committerJosef Bacik <jbacik@fb.com>
Mon, 9 Feb 2015 19:53:14 +0000 (14:53 -0500)
We have logic to fix the root locations for roots in response to a corruption
bug we had earlier.  However this work doesn't apply to reloc roots and can
screw things up worse, so make sure we skip any reloc roots that we find.
Thanks,

Signed-off-by: Josef Bacik <jbacik@fb.com>
cmds-check.c

index e74fa0f..2b08c64 100644 (file)
@@ -8886,6 +8886,8 @@ again:
 
                if (found_key.type != BTRFS_ROOT_ITEM_KEY)
                        goto next;
+               if (found_key.objectid == BTRFS_TREE_RELOC_OBJECTID)
+                       goto next;
 
                ret = maybe_repair_root_item(info, path, &found_key,
                                             trans ? 0 : 1);