Skip to content

Commit

Permalink
Btrfs: kill replicate code in replay_one_buffer
Browse files Browse the repository at this point in the history
EXTREF is treated same as REF, so we can make the code tidy.

Signed-off-by: Liu Bo <bo.li.liu@oracle.com>
Signed-off-by: Josef Bacik <jbacik@fusionio.com>
  • Loading branch information
Liu Bo authored and Josef Bacik committed Jun 14, 2013
1 parent e112e2b commit 2da1c66
Showing 1 changed file with 2 additions and 7 deletions.
9 changes: 2 additions & 7 deletions fs/btrfs/tree-log.c
Original file line number Diff line number Diff line change
Expand Up @@ -2016,13 +2016,8 @@ static int replay_one_buffer(struct btrfs_root *log, struct extent_buffer *eb,
eb, i, &key);
if (ret)
break;
} else if (key.type == BTRFS_INODE_REF_KEY) {
ret = add_inode_ref(wc->trans, root, log, path,
eb, i, &key);
if (ret && ret != -ENOENT)
break;
ret = 0;
} else if (key.type == BTRFS_INODE_EXTREF_KEY) {
} else if (key.type == BTRFS_INODE_REF_KEY ||
key.type == BTRFS_INODE_EXTREF_KEY) {
ret = add_inode_ref(wc->trans, root, log, path,
eb, i, &key);
if (ret && ret != -ENOENT)
Expand Down

0 comments on commit 2da1c66

Please sign in to comment.