From patchwork Fri Apr 1 14:23:42 2011 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Julia Lawall X-Patchwork-Id: 681491 Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by demeter1.kernel.org (8.14.4/8.14.3) with ESMTP id p31EPvpA029686 for ; Fri, 1 Apr 2011 14:25:57 GMT Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1753134Ab1DAOX4 (ORCPT ); Fri, 1 Apr 2011 10:23:56 -0400 Received: from mgw2.diku.dk ([130.225.96.92]:35616 "EHLO mgw2.diku.dk" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1751809Ab1DAOXy (ORCPT ); Fri, 1 Apr 2011 10:23:54 -0400 Received: from localhost (localhost [127.0.0.1]) by mgw2.diku.dk (Postfix) with ESMTP id A524219BC7C; Fri, 1 Apr 2011 16:23:53 +0200 (CEST) Received: from mgw2.diku.dk ([127.0.0.1]) by localhost (mgw2.diku.dk [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id 13878-12; Fri, 1 Apr 2011 16:23:50 +0200 (CEST) Received: from palace.topps.diku.dk (palace.ekstranet.diku.dk [192.38.115.202]) by mgw2.diku.dk (Postfix) with ESMTP id F3DC319BCAF; Fri, 1 Apr 2011 16:19:28 +0200 (CEST) From: Julia Lawall To: Brett Rudley Cc: kernel-janitors@vger.kernel.org, Henry Ptasinski , Dowan Kim , Roland Vossen , Arend van Spriel , Greg Kroah-Hartman , Jason Cooper , linux-wireless@vger.kernel.org, devel@driverdev.osuosl.org, linux-kernel@vger.kernel.org Subject: [PATCH 1/6] drivers/staging/brcm80211/brcmfmac/wl_iw.c: introduce missing kfree Date: Fri, 1 Apr 2011 16:23:42 +0200 Message-Id: <1301667827-20056-1-git-send-email-julia@diku.dk> X-Mailer: git-send-email 1.7.1 Sender: linux-wireless-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-wireless@vger.kernel.org X-Greylist: IP, sender and recipient auto-whitelisted, not delayed by milter-greylist-4.2.6 (demeter1.kernel.org [140.211.167.41]); Fri, 01 Apr 2011 14:25:57 +0000 (UTC) diff --git a/drivers/staging/brcm80211/brcmfmac/wl_iw.c b/drivers/staging/brcm80211/brcmfmac/wl_iw.c index b49957f..4e4cf36 100644 --- a/drivers/staging/brcm80211/brcmfmac/wl_iw.c +++ b/drivers/staging/brcm80211/brcmfmac/wl_iw.c @@ -3672,8 +3672,10 @@ int wl_iw_attach(struct net_device *dev, void *dhdp) return -ENOMEM; iscan->iscan_ex_params_p = kmalloc(params_size, GFP_KERNEL); - if (!iscan->iscan_ex_params_p) + if (!iscan->iscan_ex_params_p) { + kfree(iscan); return -ENOMEM; + } iscan->iscan_ex_param_size = params_size; iscan->sysioc_tsk = NULL;