lkml.org 
[lkml]   [2023]   [Nov]   [29]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
SubjectRe: [PATCH][next] bcachefs: Replace zero-length arrays with flexible-array members
From


On 11/29/23 14:15, Kees Cook wrote:
> On Tue, Nov 28, 2023 at 12:22:55PM -0600, Gustavo A. R. Silva wrote:
>> Fake flexible arrays (zero-length and one-element arrays) are
>> deprecated, and should be replaced by flexible-array members.
>>
>> So, replace zero-length arrays with flexible-array members
>> in multiple structures.
>>
>> Signed-off-by: Gustavo A. R. Silva <gustavoars@kernel.org>
>
> These look like straight-forward conversions. Thanks!

Yep, these also fix a buch of -Warray-bounds warnings reported
by 0-day:

https://lore.kernel.org/lkml/202311290720.TzNYq81c-lkp@intel.com/

>
> Reviewed-by: Kees Cook <keescook@chromium.org>
>

Thanks!
--
Gustavo

\
 
 \ /
  Last update: 2023-11-29 21:26    [W:2.086 / U:0.676 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site