Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1755435AbZG1SYg (ORCPT ); Tue, 28 Jul 2009 14:24:36 -0400 Received: (majordomo@vger.kernel.org) by vger.kernel.org id S1755369AbZG1SYg (ORCPT ); Tue, 28 Jul 2009 14:24:36 -0400 Received: from bipbip.grupopie.com ([195.23.16.24]:37214 "EHLO bipbip.grupopie.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1755358AbZG1SYf (ORCPT ); Tue, 28 Jul 2009 14:24:35 -0400 X-Greylist: delayed 1911 seconds by postgrey-1.27 at vger.kernel.org; Tue, 28 Jul 2009 14:24:34 EDT Message-ID: <4A6F3AEA.7090102@grupopie.com> Date: Tue, 28 Jul 2009 18:52:42 +0100 From: Paulo Marques Organization: Grupo PIE User-Agent: Thunderbird 2.0.0.21 (X11/20090310) MIME-Version: 1.0 To: Julia Lawall CC: jwoithe@physics.adelaide.edu.au, linux-acpi@vger.kernel.org, linux-kernel@vger.kernel.org, kernel-janitors@vger.kernel.org Subject: Re: [PATCH 6/12] drivers/platform/x86: Correct redundant test References: In-Reply-To: Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 7bit Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Content-Length: 1091 Lines: 38 Julia Lawall wrote: > [...] > --- > drivers/platform/x86/fujitsu-laptop.c | 3 --- > 1 files changed, 0 insertions(+), 3 deletions(-) > > diff --git a/drivers/platform/x86/fujitsu-laptop.c b/drivers/platform/x86/fujitsu-laptop.c > index 218b9a1..5306901 100644 > --- a/drivers/platform/x86/fujitsu-laptop.c > +++ b/drivers/platform/x86/fujitsu-laptop.c > @@ -745,9 +745,6 @@ static int acpi_fujitsu_remove(struct acpi_device *device, int type) > > fujitsu = acpi_driver_data(device); > > - if (!device || !acpi_driver_data(device)) > - return -EINVAL; > - Shouldn't this still do a: if (!fujitsu) return -EINVAL; to avoid dereferencing a NULL pointer below? > fujitsu->acpi_handle = NULL; > > return 0; -- Paulo Marques - www.grupopie.com "All I ask is a chance to prove that money can't make me happy." -- 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/