Revert "ext4: avoid buffer_head leak in ext4_mark_inode_used()"
This reverts commit 4e2ca3b317
.
This commit is contained in:
parent
1b82c86b6e
commit
84c804134c
1 changed files with 2 additions and 3 deletions
|
@ -757,10 +757,10 @@ int ext4_mark_inode_used(struct super_block *sb, int ino)
|
|||
struct ext4_group_desc *gdp;
|
||||
ext4_group_t group;
|
||||
int bit;
|
||||
int err;
|
||||
int err = -EFSCORRUPTED;
|
||||
|
||||
if (ino < EXT4_FIRST_INO(sb) || ino > max_ino)
|
||||
return -EFSCORRUPTED;
|
||||
goto out;
|
||||
|
||||
group = (ino - 1) / EXT4_INODES_PER_GROUP(sb);
|
||||
bit = (ino - 1) % EXT4_INODES_PER_GROUP(sb);
|
||||
|
@ -863,7 +863,6 @@ int ext4_mark_inode_used(struct super_block *sb, int ino)
|
|||
err = ext4_handle_dirty_metadata(NULL, NULL, group_desc_bh);
|
||||
sync_dirty_buffer(group_desc_bh);
|
||||
out:
|
||||
brelse(inode_bitmap_bh);
|
||||
return err;
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in a new issue