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:   Thu, 21 Feb 2019 16:24:10 -0800 (PST)
From:   David Miller <davem@...emloft.net>
To:     arnd@...db.de
Cc:     courmisch@...il.com, natechancellor@...il.com, remi@...lab.net,
        netdev@...r.kernel.org, linux-kernel@...r.kernel.org
Subject: Re: [PATCH] phonet: fix building with clang

From: Arnd Bergmann <arnd@...db.de>
Date: Tue, 19 Feb 2019 22:53:50 +0100

> clang warns about overflowing the data[] member in the struct pnpipehdr:
> 
> net/phonet/pep.c:295:8: warning: array index 4 is past the end of the array (which contains 1 element) [-Warray-bounds]
>                         if (hdr->data[4] == PEP_IND_READY)
>                             ^         ~
> include/net/phonet/pep.h:66:3: note: array 'data' declared here
>                 u8              data[1];
> 
> Using a flexible array member at the end of the struct avoids the
> warning, but since we cannot have a flexible array member inside
> of the union, each index now has to be moved back by one, which
> makes it a little uglier.
> 
> Signed-off-by: Arnd Bergmann <arnd@...db.de>

Applied, thank you.

Powered by blists - more mailing lists