Re: [PATCH v9] locale: memory leak in newlocale [BZ #25770]
Dmitry Kovalenko
d.kovalenko@postgrespro.ru
Fri Jun 6 06:36:29 GMT 2025
Hello,
> The first assert
>
> assert (locale_path_ptr != NULL);
>
> is not removed for some reason. This looks like a GCC bug to me. GCC
> is generally able to determine that addresses on the stack cannot be
> null.
I understood what you said )
I think for removing the such code «the global code optimization» is required.
Usually (as I understand) «the global code optimization» is used to build a final binaries where all debug checks already are removed )
I will replace these two asserts with *newlocale_path_ptr = NULL in v10.
> The one after __argz_add_sep does not get optimized out, either, but that's correct, and I think the assert is valid.
I will save this assert.
Thanks,
Dmitry Kovalenko.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://sourceware.org/pipermail/libc-alpha/attachments/20250606/8dec53ca/attachment.htm>
More information about the Libc-alpha
mailing list