[PATCH] vboxsf: Add __nonstring annotations for unterminated strings

2025-03-11 Thread Kees Cook
When a character array without a terminating NUL character has a static initializer, GCC 15's -Wunterminated-string-initialization will only warn if the array lacks the "nonstring" attribute[1]. Mark the arrays with __nonstring to and correctly identify the char array as "not a C string" and thereb

Re: [PATCH] vboxsf: Add __nonstring annotations for unterminated strings

2025-03-11 Thread Christian Brauner
On Mon, 10 Mar 2025 15:25:31 -0700, Kees Cook wrote: > When a character array without a terminating NUL character has a static > initializer, GCC 15's -Wunterminated-string-initialization will only > warn if the array lacks the "nonstring" attribute[1]. Mark the arrays > with __nonstring to and cor

Re: [PATCH] vboxsf: Add __nonstring annotations for unterminated strings

2025-03-11 Thread Hans de Goede
Hi, On 10-Mar-25 11:25 PM, Kees Cook wrote: > When a character array without a terminating NUL character has a static > initializer, GCC 15's -Wunterminated-string-initialization will only > warn if the array lacks the "nonstring" attribute[1]. Mark the arrays > with __nonstring to and correctly i