[<prev] [next>] [<thread-prev] [day] [month] [year] [list]
Message-ID: <20140517224255.GJ15585@mwanda>
Date: Sun, 18 May 2014 01:42:55 +0300
From: Dan Carpenter <dan.carpenter@...cle.com>
To: Peter Senna Tschudin <peter.senna@...il.com>
Cc: Dominik Brodowski <linux@...inikbrodowski.net>,
Thomas Renninger <trenn@...e.de>,
"linux-kernel@...r.kernel.org" <linux-kernel@...r.kernel.org>,
"Rafael J. Wysocki" <rafael.j.wysocki@...el.com>,
Alan Cox <alan@...ux.intel.com>,
kernel-janitors@...r.kernel.org
Subject: Re: [PATCH 2/4] cpupower: Remove redundant error check
On Sun, May 18, 2014 at 12:31:29AM +0200, Peter Senna Tschudin wrote:
> >
> > I am currently involved in a number of threads, not just yours, where I
> > am encouraging people to replace ambiguous returns with "return 0;".
> > This is my life now.
> So maybe you like this list of 160 places in which the return variable
> is initialized and only used as parameter to return(The list look
> good, but I haven't reviewed all 160, so there could be problems):
> http://pastebin.com/5kAbCP2e
Fantastic! :) These things are easy to review because if it's wrong
then the compile will break.
>
> Does it worth doing something about those trivial cases?
>
> Do you have more examples of ambiguous returns, so I can help you hunt them?
The main thing is what your check finds. If you know that ret is zero
then return zero.
regards,
dan carpenter
--
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