Re: base64: gcc-15 compile issue

2024-12-21 Thread Paul Eggert
On 2024-12-21 11:58, Jeffrey Walton wrote: The string literal includes the trailing NULL, so the literal is 65 chars, not 64 char. Yes, and the C standard says this is OK; there is a special rule saying that definitions like 'char arr[3] = "abc";' are fine. I reported the overenthusiastic GC

Re: base64: gcc-15 compile issue

2024-12-21 Thread Pádraig Brady
On 21/12/2024 19:58, Jeffrey Walton wrote: On Sat, Dec 21, 2024 at 9:45 AM Bruno Haible via Gnulib discussion list wrote: Rudi Heitbaum wrote: When compiling grub-2.12 with gcc-15-20241208 the following line causes the following error: https://git.savannah.gnu.org/cgit/gnulib.git/tree/lib/ba

Re: base64: gcc-15 compile issue

2024-12-21 Thread Jeffrey Walton
On Sat, Dec 21, 2024 at 9:45 AM Bruno Haible via Gnulib discussion list wrote: > > Rudi Heitbaum wrote: > > When compiling grub-2.12 with gcc-15-20241208 the following line causes > > the following error: > > > > https://git.savannah.gnu.org/cgit/gnulib.git/tree/lib/base64.c#n62 > > > > ../../grub

Re: base64: gcc-15 compile issue

2024-12-21 Thread Collin Funk
Bruno Haible via Gnulib discussion list writes: > In this case, the code is perfectly fine: it initializes an array of > size 64 with 64 characters. There is no better way to write such an > initialization. If I interpret the warning correctly, I don't think it would trigger with something like

Re: base64: gcc-15 compile issue

2024-12-21 Thread Bruno Haible via Gnulib discussion list
Hi, Rudi Heitbaum wrote: > When compiling grub-2.12 with gcc-15-20241208 the following line causes > the following error: > > https://git.savannah.gnu.org/cgit/gnulib.git/tree/lib/base64.c#n62 > > ../../grub-core/lib/gnulib/base64.c:65:3: > error: initializer-string for array of 'char' is too

base64: gcc-15 compile issue

2024-12-21 Thread Rudi Heitbaum
When compiling grub-2.12 with gcc-15-20241208 the following line causes the following error: https://git.savannah.gnu.org/cgit/gnulib.git/tree/lib/base64.c#n62 ../../grub-core/lib/gnulib/base64.c:65:3: error: initializer-string for array of 'char' is too long [-Werror=unterminated-string-init