[<prev] [next>] [<thread-prev] [day] [month] [year] [list]
Message-ID: <20130601185204.GF16790@sirena.org.uk>
Date: Sat, 1 Jun 2013 19:52:04 +0100
From: Mark Brown <broonie@...nel.org>
To: Vinod Koul <vinod.koul@...el.com>
Cc: linux-kernel@...r.kernel.org
Subject: Re: [PATCH 2/2] regmap: fix return of uninitialized value
On Thu, May 30, 2013 at 09:54:02PM +0530, Vinod Koul wrote:
> struct regmap_debugfs_off_cache *c = NULL;
> loff_t p = 0;
> - unsigned int i, ret;
> + unsigned int i, ret = 0;
Two problems here. One is that we shouldn't mix initialised and
non-initialised declarations on one line and the other is that just
squashing a value in isn't a great fix for this sort of thing - it's
just shutting the warning up but perhaps the compiler has actually
spotted some control flow error and there's more wrong than just a
missing initialisation.
Download attachment "signature.asc" of type "application/pgp-signature" (837 bytes)
Powered by blists - more mailing lists