]> git.baikalelectronics.ru Git - kernel.git/commit
btrfs: Fix memory leakage in the tree-log.c
authorGeyslan G. Bem <geyslan@gmail.com>
Fri, 11 Oct 2013 18:35:45 +0000 (15:35 -0300)
committerChris Mason <chris.mason@fusionio.com>
Tue, 12 Nov 2013 03:00:11 +0000 (22:00 -0500)
commit81c331e70c34cd7f0a883ac22cebe1f8e089e438
tree36d9e492b02fc0f6debab21632a021e26206db01
parent8e5374ed7fa314a88aceb54867827debd24dd453
btrfs: Fix memory leakage in the tree-log.c

In add_inode_ref() function:

Initializes local pointers.

Reduces the logical condition with the __add_inode_ref() return
value by using only one 'goto out'.

Centralizes the exiting, ensuring the freeing of all used memory.

Signed-off-by: Geyslan G. Bem <geyslan@gmail.com>
Reviewed-by: Stefan Behrens <sbehrens@giantdisaster.de>
Signed-off-by: Josef Bacik <jbacik@fusionio.com>
Signed-off-by: Chris Mason <chris.mason@fusionio.com>
fs/btrfs/tree-log.c