From: Jan Schmidt Date: Wed, 4 Jul 2012 14:15:02 +0000 (-0600) Subject: Btrfs: fix buffer leak in btrfs_next_old_leaf X-Git-Url: http://git.lede-project.org./?a=commitdiff_plain;h=e6466e354a5c23717325adecf387f93be4b9c830;p=openwrt%2Fstaging%2Fblogic.git Btrfs: fix buffer leak in btrfs_next_old_leaf When calling btrfs_next_old_leaf, we were leaking an extent buffer in the rare case of using the deadlock avoidance code needed for the tree mod log. Signed-off-by: Jan Schmidt Signed-off-by: Josef Bacik --- diff --git a/fs/btrfs/ctree.c b/fs/btrfs/ctree.c index 8206b3900587..67fe46fdee6f 100644 --- a/fs/btrfs/ctree.c +++ b/fs/btrfs/ctree.c @@ -5127,6 +5127,7 @@ again: * locked. To solve this situation, we give up * on our lock and cycle. */ + free_extent_buffer(next); btrfs_release_path(path); cond_resched(); goto again;