Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S932181Ab2F2PQy (ORCPT ); Fri, 29 Jun 2012 11:16:54 -0400 Received: from a.ns.miles-group.at ([95.130.255.143]:47835 "EHLO radon.swed.at" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1755912Ab2F2POk (ORCPT ); Fri, 29 Jun 2012 11:14:40 -0400 From: Richard Weinberger To: linux-mtd@lists.infradead.org Cc: linux-kernel@vger.kernel.org, adrian.hunter@intel.com, Heinz.Egger@linutronix.de, thomas.wucher@linutronix.de, shmulik.ladkani@gmail.com, tglx@linutronix.de, tim.bird@am.sony.com, Marius.Mazarel@ugal.ro, artem.bityutskiy@linux.intel.com, nyoushchenko@mvista.com, Richard Weinberger Subject: [PATCH 01/11] UBI: Fastmap: Fix mem leak in error path Date: Fri, 29 Jun 2012 17:14:19 +0200 Message-Id: <1340982869-77042-2-git-send-email-richard@nod.at> X-Mailer: git-send-email 1.7.6.5 In-Reply-To: <1340982869-77042-1-git-send-email-richard@nod.at> References: <1340982869-77042-1-git-send-email-richard@nod.at> Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Content-Length: 863 Lines: 32 Signed-off-by: Richard Weinberger --- drivers/mtd/ubi/attach.c | 4 ++-- 1 files changed, 2 insertions(+), 2 deletions(-) diff --git a/drivers/mtd/ubi/attach.c b/drivers/mtd/ubi/attach.c index 3d9be42..bd3a8f5 100644 --- a/drivers/mtd/ubi/attach.c +++ b/drivers/mtd/ubi/attach.c @@ -1325,12 +1325,12 @@ int ubi_attach(struct ubi_device *ubi, int force_scan) scan_ai = alloc_ai(); if (!scan_ai) - goto out_ai; + goto out_wl; err = scan_all(ubi, scan_ai); if (err) { kfree(scan_ai); - goto out_ai; + goto out_wl; } self_check_eba(ubi, ai, scan_ai); -- 1.7.6.5 -- To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html Please read the FAQ at http://www.tux.org/lkml/