From patchwork Sat Mar 20 14:12:52 2010 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Wolfram Sang X-Patchwork-Id: 87133 Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by demeter.kernel.org (8.14.3/8.14.3) with ESMTP id o2KEI0TF032677 for ; Sat, 20 Mar 2010 14:18:00 GMT Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1752751Ab0CTOR5 (ORCPT ); Sat, 20 Mar 2010 10:17:57 -0400 Received: from metis.ext.pengutronix.de ([92.198.50.35]:59101 "EHLO metis.ext.pengutronix.de" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1752649Ab0CTOOr (ORCPT ); Sat, 20 Mar 2010 10:14:47 -0400 Received: from themisto.ext.pengutronix.de ([92.198.50.58] helo=pengutronix.de) by metis.ext.pengutronix.de with esmtp (Exim 4.71) (envelope-from ) id 1NszRn-0004De-VD; Sat, 20 Mar 2010 15:14:42 +0100 From: Wolfram Sang To: kernel-janitors@vger.kernel.org Cc: linux-i2c@vger.kernel.org, linux-kernel@vger.kernel.org, Wolfram Sang , Mauro Carvalho Chehab , linux-media@vger.kernel.org Date: Sat, 20 Mar 2010 15:12:52 +0100 Message-Id: <1269094385-16114-12-git-send-email-w.sang@pengutronix.de> X-Mailer: git-send-email 1.7.0 In-Reply-To: <1269094385-16114-1-git-send-email-w.sang@pengutronix.de> References: <1269094385-16114-1-git-send-email-w.sang@pengutronix.de> X-SA-Exim-Connect-IP: 92.198.50.58 X-SA-Exim-Mail-From: w.sang@pengutronix.de X-Spam-Checker-Version: SpamAssassin 3.3.0 (2010-01-18) on metis.extern.pengutronix.de X-Spam-Level: X-Spam-Status: No, score=-2.0 required=4.5 tests=AWL,BAYES_00, KHOP_SC_TOP_CIDR8,T_RP_MATCHES_RCVD shortcircuit=no autolearn=ham version=3.3.0 Subject: [PATCH 11/24] media/radio/si470x: fix dangling pointers X-SA-Exim-Version: 4.2.1 (built Sat, 01 Aug 2009 12:09:26 +0000) X-SA-Exim-Scanned: Yes (on metis.ext.pengutronix.de) X-PTX-Original-Recipient: linux-media@vger.kernel.org Sender: linux-media-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-media@vger.kernel.org X-Greylist: IP, sender and recipient auto-whitelisted, not delayed by milter-greylist-4.2.3 (demeter.kernel.org [140.211.167.41]); Sat, 20 Mar 2010 14:18:01 +0000 (UTC) diff --git a/drivers/media/radio/si470x/radio-si470x-i2c.c b/drivers/media/radio/si470x/radio-si470x-i2c.c index 5466015..2dabfac 100644 --- a/drivers/media/radio/si470x/radio-si470x-i2c.c +++ b/drivers/media/radio/si470x/radio-si470x-i2c.c @@ -480,8 +480,8 @@ static __devexit int si470x_i2c_remove(struct i2c_client *client) free_irq(client->irq, radio); cancel_work_sync(&radio->radio_work); video_unregister_device(radio->videodev); - kfree(radio); i2c_set_clientdata(client, NULL); + kfree(radio); return 0; }