lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [day] [month] [year] [list]
Date:	Fri, 26 Sep 2008 16:45:54 +0200
From:	Takashi Iwai <tiwai@...e.de>
To:	Mark Brown <broonie@...ena.org.uk>
Cc:	Julien Brunel <brunel@...u.dk>,
	Geoffrey Wossum <geoffrey@...er.net>,
	linux-kernel@...r.kernel.org, kernel-janitors@...r.kernel.org
Subject: Re: [PATCH] sound/soc/at32: Useless NULL test

At Fri, 26 Sep 2008 15:00:23 +0100,
Mark Brown wrote:
> 
> On Fri, Sep 26, 2008 at 03:23:46PM +0200, Julien Brunel wrote:
> 
> > The test (ssc != NULL) can only be reached if the call to the function
> > ssc_request, the result of which ssc is assigned, succeeds. Moreover,
> > statements assign NULL to ssc just before a return, which is useless
> > since it is a local variable. So, we suggest to delete the test and
> > the two assignments.
> 
> Acked-by: Mark Brown <broonie@...nsource.wolfsonmicro.com>

Applied now.  Thanks.

> For future reference if you're submitting other similar things (which I
> guess you will given that you've got a tool to check for this stuff)
> it'd be helpful if you could rewrite the explanation for the NULL test
> to be something like:
> 
>     The test (ssc != NULL) is redundant since it can only be reached
>     when ssc is guaranteed to have been set to a valid ssc.
> 
> which is much easier to parse.

Agreed :)


Takashi
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ