From 4ea3c4036c6f4300e33ae0e03b5c2d57d4a161af Mon Sep 17 00:00:00 2001 From: Jiri Slaby Date: Wed, 6 Jan 2010 16:57:22 +0000 Subject: [PATCH] --- yaml --- r: 179623 b: refs/heads/master c: 2423fdfb96e3f9ff3baeb6c4c78d74145547891d h: refs/heads/master i: 179621: c3de229a0db0fd5941b376e36d717dc4a718371f 179619: 1d26444f331fc9ae1ee794d47ab255b41a1b89bb 179615: 598058214715268d2a2678d4fe8ec6778faa9f98 v: v3 --- [refs] | 2 +- trunk/fs/btrfs/relocation.c | 4 +++- trunk/fs/btrfs/volumes.c | 4 +++- 3 files changed, 7 insertions(+), 3 deletions(-) diff --git a/[refs] b/[refs] index 74a44ab08349..54dfe6b2b560 100644 --- a/[refs] +++ b/[refs] @@ -1,2 +1,2 @@ --- -refs/heads/master: a038fab0cb873c75d6675e2bcffce8a3935bdce7 +refs/heads/master: 2423fdfb96e3f9ff3baeb6c4c78d74145547891d diff --git a/trunk/fs/btrfs/relocation.c b/trunk/fs/btrfs/relocation.c index a9728680eca8..ed3e4a2ec2c8 100644 --- a/trunk/fs/btrfs/relocation.c +++ b/trunk/fs/btrfs/relocation.c @@ -3281,8 +3281,10 @@ static noinline_for_stack int relocate_block_group(struct reloc_control *rc) return -ENOMEM; path = btrfs_alloc_path(); - if (!path) + if (!path) { + kfree(cluster); return -ENOMEM; + } rc->extents_found = 0; rc->extents_skipped = 0; diff --git a/trunk/fs/btrfs/volumes.c b/trunk/fs/btrfs/volumes.c index 198cff28766d..220dad5db017 100644 --- a/trunk/fs/btrfs/volumes.c +++ b/trunk/fs/btrfs/volumes.c @@ -2649,8 +2649,10 @@ static int __btrfs_map_block(struct btrfs_mapping_tree *map_tree, int rw, em = lookup_extent_mapping(em_tree, logical, *length); read_unlock(&em_tree->lock); - if (!em && unplug_page) + if (!em && unplug_page) { + kfree(multi); return 0; + } if (!em) { printk(KERN_CRIT "unable to find logical %llu len %llu\n",