This is the mail archive of the
mailing list for the libstdc++ project.
Re: [patch] Enable lightweight checks with _GLIBCXX_ASSERTIONS.
- From: Florian Weimer <fweimer at redhat dot com>
- To: Martin Sebor <msebor at gmail dot com>, Jonathan Wakely <jwakely at redhat dot com>
- Cc: libstdc++ at gcc dot gnu dot org, gcc-patches at gcc dot gnu dot org, FranÃois Dumont <frs dot dumont at gmail dot com>
- Date: Mon, 14 Sep 2015 11:57:43 +0200
- Subject: Re: [patch] Enable lightweight checks with _GLIBCXX_ASSERTIONS.
- Authentication-results: sourceware.org; auth=none
- References: <20150907182755 dot GP2631 at redhat dot com> <87r3mauiud dot fsf at mid dot deneb dot enyo dot de> <20150907195939 dot GT2631 at redhat dot com> <55EEF828 dot 4060707 at redhat dot com> <20150908154535 dot GX2631 at redhat dot com> <55F05728 dot 1000209 at redhat dot com> <55F1B041 dot 5060507 at gmail dot com> <55F1B1F5 dot 4060300 at redhat dot com> <55F1B682 dot 1040109 at gmail dot com>
On 09/10/2015 06:57 PM, Martin Sebor wrote:
>>> There is quite a bit of documentation of _FORTIFY_SOURCE that explains
>>> its effect on user code.
>> I think there are only random blog articles discussing aspects of it,
>> most of them slightly incorrect or outdated.
> _FORTIFY_SOURCE is a GLIBC feature test macro. It's documented
> in <features.h> and mentioned in some of its online manuals.
> For example:
> or here:
Oh, so there is an out-dated man-page as well. :-/
The fd_set checks added in glibc 2.15 are missing. That caused some
backslash because some folks were actually abusing FD_SET and related
macros. Nothing too severe, and in the end, we stood our ground. I
expect the libstdc++ changes to be similar.
Again, my main argument is that the main users of _FORTIFY_SOURCE are
distributions, and they would inject whatever preprocessor macro enables
the new libstdc++ checks anyway, so saving them that work would be
Florian Weimer / Red Hat Product Security