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 for Android: free password hash cracker in your pocket
[<prev] [next>] [<thread-prev] [day] [month] [year] [list]
Date:   Thu, 07 Jun 2018 16:55:16 -0400 (EDT)
From:   David Miller <davem@...emloft.net>
To:     geert@...ux-m68k.org
Cc:     alexandre.belloni@...tlin.com, andrew@...n.ch, arnd@...db.de,
        netdev@...r.kernel.org, linux-kernel@...r.kernel.org
Subject: Re: [PATCH] net: mscc: ocelot: Fix uninitialized error in
 ocelot_netdevice_event()

From: Geert Uytterhoeven <geert@...ux-m68k.org>
Date: Thu,  7 Jun 2018 15:10:30 +0200

> With gcc-4.1.2:
> 
>     drivers/net/ethernet/mscc/ocelot.c: In function ‘ocelot_netdevice_event’:
>     drivers/net/ethernet/mscc/ocelot.c:1129: warning: ‘ret’ may be used uninitialized in this function
> 
> If the list iterated over by netdev_for_each_lower_dev() is empty, ret
> is never initialized, and converted into a notifier return value.
> 
> Fix this by preinitializing ret to zero.
> 
> Fixes: a556c76adc052c97 ("net: mscc: Add initial Ocelot switch support")
> Signed-off-by: Geert Uytterhoeven <geert@...ux-m68k.org>
> ---
> This may be unlikely to happen, but given the notifier is called for any
> (also non-ocelot) network device, better be safe than sorry.

Applied.

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ