From mboxrd@z Thu Jan 1 00:00:00 1970 From: Michal Simek Date: Mon, 29 Aug 2011 07:50:32 +0200 Subject: [U-Boot] [PATCH 7/8] net: emaclite: Free allocated space for device In-Reply-To: <201108261525.11054.vapier@gentoo.org> References: <1314362843-18214-1-git-send-email-monstr@monstr.eu> <1314362843-18214-6-git-send-email-monstr@monstr.eu> <1314362843-18214-7-git-send-email-monstr@monstr.eu> <201108261525.11054.vapier@gentoo.org> Message-ID: <4E5B28A8.9070201@monstr.eu> List-Id: MIME-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit To: u-boot@lists.denx.de Mike Frysinger wrote: > On Friday, August 26, 2011 08:47:22 Michal Simek wrote: >> --- a/drivers/net/xilinx_emaclite.c >> +++ b/drivers/net/xilinx_emaclite.c >> @@ -356,8 +356,10 @@ int xilinx_emaclite_initialize (bd_t *bis, int >> base_addr) return -1; >> >> emaclite = calloc(1, sizeof(struct xemaclite)); >> - if (emaclite == NULL) >> + if (emaclite == NULL) { >> + free(dev); >> return -1; >> + } > > since this bug was introduced by your patch 5/8, please squash it into that > rather than sending out a known buggy one aah. Good point. Thanks, Michal -- Michal Simek, Ing. (M.Eng) w: www.monstr.eu p: +42-0-721842854 Maintainer of Linux kernel 2.6 Microblaze Linux - http://www.monstr.eu/fdt/ Microblaze U-BOOT custodian