Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1755030Ab2HEVA0 (ORCPT ); Sun, 5 Aug 2012 17:00:26 -0400 Received: from mail-wg0-f44.google.com ([74.125.82.44]:58089 "EHLO mail-wg0-f44.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1754977Ab2HEVAZ (ORCPT ); Sun, 5 Aug 2012 17:00:25 -0400 Date: Sun, 5 Aug 2012 23:00:44 +0200 From: Daniel Vetter To: Jesper Juhl Cc: David Airlie , Daniel Vetter , Jesse Barnes , linux-kernel@vger.kernel.org, dri-devel@lists.freedesktop.org Subject: Re: [PATCH] drm/i915: Fix mem leak in intel_sdvo_write_cmd() Message-ID: <20120805210044.GE12232@phenom.ffwll.local> Mail-Followup-To: Jesper Juhl , David Airlie , Jesse Barnes , linux-kernel@vger.kernel.org, dri-devel@lists.freedesktop.org References: MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: X-Operating-System: Linux phenom 3.4.0-rc3+ User-Agent: Mutt/1.5.21 (2010-09-15) Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Content-Length: 660 Lines: 18 On Tue, Jul 31, 2012 at 10:31:15PM +0200, Jesper Juhl wrote: > If the allocation of 'buf' succeeds but the allocation of 'msgs' fails > we'll return false and leak 'buf' when it goes out of scope. > > Signed-off-by: Jesper Juhl I've already merged a similar patch from Alan Cox for -fixes, should land in 3.6 soonish. -Daniel -- Daniel Vetter Mail: daniel@ffwll.ch Mobile: +41 (0)79 365 57 48 -- 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/