Skip to content

Commit

Permalink
fix found_type decrement in btrfs_truncate_in_trans
Browse files Browse the repository at this point in the history
found_type has already been decreased by codes above the change,  I
think decrease it by one again doesn't make sense.

Signed-off-by: Chris Mason <chris.mason@oracle.com>
  • Loading branch information
Yan authored and Chris Mason committed Sep 25, 2008
1 parent cf67582 commit a61721d
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion fs/btrfs/inode.c
Original file line number Diff line number Diff line change
Expand Up @@ -581,7 +581,7 @@ static int btrfs_truncate_in_trans(struct btrfs_trans_handle *trans,
} else {
break;
}
btrfs_set_key_type(&key, found_type - 1);
btrfs_set_key_type(&key, found_type);
continue;
}
if (btrfs_disk_key_offset(found_key) >= inode->i_size)
Expand Down

0 comments on commit a61721d

Please sign in to comment.