From: Andrew Morton Date: Thu, 8 Dec 2011 04:32:10 +0000 (+1100) Subject: mm-vmallocc-eliminate-extra-loop-in-pcpu_get_vm_areas-error-path-fix X-Git-Tag: next-20111212~1^2~212 X-Git-Url: https://git.karo-electronics.de/?a=commitdiff_plain;h=e2a35ba2be6beed6b326d45981da8761be0551ed;p=karo-tx-linux.git mm-vmallocc-eliminate-extra-loop-in-pcpu_get_vm_areas-error-path-fix remove now-unneeded tests Cc: Kautuk Consul Signed-off-by: Andrew Morton --- diff --git a/mm/vmalloc.c b/mm/vmalloc.c index ccc8b1b08293..ee3432ed8cd9 100644 --- a/mm/vmalloc.c +++ b/mm/vmalloc.c @@ -2476,10 +2476,8 @@ found: err_free: for (area = 0; area < nr_vms; area++) { - if (vas) - kfree(vas[area]); - if (vms) - kfree(vms[area]); + kfree(vas[area]); + kfree(vms[area]); } err_free2: kfree(vas);