Commit a564d6ef authored by Vasily Averin's avatar Vasily Averin Committed by Kleber Sacilotto de Souza

ext4: fix possible inode leak in the retry loop of ext4_resize_fs()

BugLink: https://bugs.launchpad.net/bugs/1810947

commit db6aee62 upstream.

Fixes: 1c6bd717 ("ext4: convert file system to meta_bg if needed ...")
Signed-off-by: default avatarVasily Averin <vvs@virtuozzo.com>
Signed-off-by: default avatarTheodore Ts'o <tytso@mit.edu>
Cc: stable@kernel.org # 3.7
Signed-off-by: default avatarGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Signed-off-by: default avatarJuerg Haefliger <juergh@canonical.com>
Signed-off-by: default avatarKleber Sacilotto de Souza <kleber.souza@canonical.com>
parent a860c2f9
...@@ -2026,6 +2026,10 @@ int ext4_resize_fs(struct super_block *sb, ext4_fsblk_t n_blocks_count) ...@@ -2026,6 +2026,10 @@ int ext4_resize_fs(struct super_block *sb, ext4_fsblk_t n_blocks_count)
n_blocks_count_retry = 0; n_blocks_count_retry = 0;
free_flex_gd(flex_gd); free_flex_gd(flex_gd);
flex_gd = NULL; flex_gd = NULL;
if (resize_inode) {
iput(resize_inode);
resize_inode = NULL;
}
goto retry; goto retry;
} }
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment