Repository navigation
Commit 703c88e
Btrfs: fix tracking of orphan inode count
In inode.c:btrfs_orphan_add() if we failed to insert the orphan
item, we would return without decrementing the orphan count that
we just incremented before attempting the insertion, leaving the
orphan inode count wrong.
In inode.c:btrfs_orphan_del(), we were decrementing the inode
orphan count if the bit BTRFS_INODE_ORPHAN_META_RESERVED was set,
which is logically wrong because it should be decremented if the
bit BTRFS_INODE_HAS_ORPHAN_ITEM was set - after all we increment
the count when we set the bit BTRFS_INODE_HAS_ORPHAN_ITEM elsewhere.
Signed-off-by: Filipe David Borba Manana <fdmanana@gmail.com>
Signed-off-by: Josef Bacik <jbacik@fusionio.com>
Signed-off-by: Chris Mason <chris.mason@fusionio.com>1 parent fe09e16 commit 703c88e
1 file changed
Lines changed: 8 additions & 5 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
2969 | 2969 | | |
2970 | 2970 | | |
2971 | 2971 | | |
| 2972 | + | |
2972 | 2973 | | |
2973 | 2974 | | |
2974 | 2975 | | |
| |||
3018 | 3019 | | |
3019 | 3020 | | |
3020 | 3021 | | |
3021 | | - | |
3022 | | - | |
3023 | | - | |
3024 | | - | |
3025 | | - | |
| 3022 | + | |
3026 | 3023 | | |
| 3024 | + | |
| 3025 | + | |
| 3026 | + | |
3027 | 3027 | | |
3028 | 3028 | | |
| 3029 | + | |
| 3030 | + | |
| 3031 | + | |
3029 | 3032 | | |
3030 | 3033 | | |
3031 | 3034 | | |
| |||
0 commit comments