From patchwork Wed May 8 13:46:27 2013 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Laurent Pinchart X-Patchwork-Id: 2539411 Return-Path: X-Original-To: patchwork-linux-media@patchwork.kernel.org Delivered-To: patchwork-process-083081@patchwork2.kernel.org Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by patchwork2.kernel.org (Postfix) with ESMTP id CA26ADF2E5 for ; Wed, 8 May 2013 13:47:12 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1755910Ab3EHNrI (ORCPT ); Wed, 8 May 2013 09:47:08 -0400 Received: from perceval.ideasonboard.com ([95.142.166.194]:58556 "EHLO perceval.ideasonboard.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1755272Ab3EHNqw (ORCPT ); Wed, 8 May 2013 09:46:52 -0400 Received: from avalon.ideasonboard.com (unknown [91.178.146.12]) by perceval.ideasonboard.com (Postfix) with ESMTPSA id 5856535A4F for ; Wed, 8 May 2013 15:46:24 +0200 (CEST) From: Laurent Pinchart To: linux-media@vger.kernel.org Subject: [PATCH RESEND 2/9] tvp514x: Fix double free Date: Wed, 8 May 2013 15:46:27 +0200 Message-Id: <1368020794-21264-3-git-send-email-laurent.pinchart@ideasonboard.com> X-Mailer: git-send-email 1.8.1.5 In-Reply-To: <1368020794-21264-1-git-send-email-laurent.pinchart@ideasonboard.com> References: <1368020794-21264-1-git-send-email-laurent.pinchart@ideasonboard.com> Sender: linux-media-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-media@vger.kernel.org The tvp514x data structure is allocated using devm_kzalloc(). Freeing it explictly would result in a double free. Fix it. Signed-off-by: Laurent Pinchart Acked-by: Lad, Prabhakar --- drivers/media/i2c/tvp514x.c | 1 - 1 file changed, 1 deletion(-) diff --git a/drivers/media/i2c/tvp514x.c b/drivers/media/i2c/tvp514x.c index ab8f3fe..7438e01 100644 --- a/drivers/media/i2c/tvp514x.c +++ b/drivers/media/i2c/tvp514x.c @@ -1120,7 +1120,6 @@ tvp514x_probe(struct i2c_client *client, const struct i2c_device_id *id) if (ret < 0) { v4l2_err(sd, "%s decoder driver failed to register !!\n", sd->name); - kfree(decoder); return ret; } #endif