Skip to content

Commit

Permalink
ext2: Fix memory leak in ext2_fill_super() in case of a failed mount
Browse files Browse the repository at this point in the history
Signed-off-by: Manish Katiyar <mkatiyar@gmail.com>
Signed-off-by: "Theodore Ts'o" <tytso@mit.edu>
  • Loading branch information
Manish Katiyar authored and Theodore Ts'o committed May 18, 2009
1 parent de5ce03 commit 0f7ee7c
Showing 1 changed file with 1 addition and 0 deletions.
1 change: 1 addition & 0 deletions fs/ext2/super.c
Original file line number Diff line number Diff line change
Expand Up @@ -1093,6 +1093,7 @@ static int ext2_fill_super(struct super_block *sb, void *data, int silent)
brelse(bh);
failed_sbi:
sb->s_fs_info = NULL;
kfree(sbi->s_blockgroup_lock);
kfree(sbi);
return ret;
}
Expand Down

0 comments on commit 0f7ee7c

Please sign in to comment.