Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 64a3d537 authored by Theodore Ts'o's avatar Theodore Ts'o Committed by Greg Kroah-Hartman
Browse files

ext4: avoid possible double brelse() in add_new_gdb() on error path



commit 4f32c38b4662312dd3c5f113d8bdd459887fb773 upstream.

Fixes: b4097142 ("ext4: add error checking to calls to ...")
Reported-by: default avatarVasily Averin <vvs@virtuozzo.com>
Signed-off-by: default avatarTheodore Ts'o <tytso@mit.edu>
Cc: stable@kernel.org # 2.6.38
Signed-off-by: default avatarGreg Kroah-Hartman <gregkh@linuxfoundation.org>
parent 110a1994
Loading
Loading
Loading
Loading
+1 −0
Original line number Diff line number Diff line
@@ -871,6 +871,7 @@ static int add_new_gdb(handle_t *handle, struct inode *inode,
	err = ext4_handle_dirty_metadata(handle, NULL, gdb_bh);
	if (unlikely(err)) {
		ext4_std_error(sb, err);
		iloc.bh = NULL;
		goto exit_inode;
	}
	brelse(dind);