[PATCH] cache: fix GCC warning and avoid variable shadowing

Thomas Haller thaller at redhat.com
Fri Dec 2 04:39:08 PST 2016


On Fri, 2016-12-02 at 11:46 +0100, Tobias Klauser wrote:
> Fix the following GCC warning, introduced in commit 66d032ad443a
> ("cache_mngr: add include callback v2"):
> 
> cache.c: In function ‘cache_include.isra.3’:
> cache.c:810:6: warning: ‘diff’ may be used uninitialized in this
> function [-Wmaybe-uninitialized]
>       cb_v2(cache, clone, obj, diff,
>             ^
> 
> Also don't redeclare the uint64_t diff variable, to avoid shadowing.
> 
> Signed-off-by: Tobias Klauser <tklauser at distanz.ch>
> ---


Hi Tobias,

merged as https://github.com/thom311/libnl/commit/7e88d00c095dba3513e15f9ca387df47cfcb0ab0

Thanks,
Thomas
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 819 bytes
Desc: This is a digitally signed message part
URL: <http://lists.infradead.org/pipermail/libnl/attachments/20161202/bd7e5330/attachment.sig>


More information about the libnl mailing list