[Bug dynamic-link/22149] cache.c:save_cache creates zero-size VLA

fweimer at redhat dot com sourceware-bugzilla@sourceware.org
Mon Nov 27 12:10:00 GMT 2017


https://sourceware.org/bugzilla/show_bug.cgi?id=22149

--- Comment #3 from Florian Weimer <fweimer at redhat dot com> ---
(In reply to Andreas Schwab from comment #0)
> The C standard does not allow creating a VLA with zero size, but save_cache
> tries to do so when the padding is zero.  This causes misbehaviour with the
> proposed -fstack-clash-protection option of gcc which assumes that it can
> always emit at least one stack probe to the allocated space.

Also seen in _nl_load_locale_from_archive and _dl_fini.  GCC consensus is that
those were GCC bugs:

https://gcc.gnu.org/ml/gcc-patches/2017-11/msg01150.html

-- 
You are receiving this mail because:
You are on the CC list for the bug.


More information about the Glibc-bugs mailing list