This is the mail archive of the
binutils@sourceware.org
mailing list for the binutils project.
Re: [patch] ld: optimize vfinfo output slightly
- From: "Joseph S. Myers" <joseph at codesourcery dot com>
- To: Ian Lance Taylor <iant at google dot com>
- Cc: Mike Frysinger <vapier at gentoo dot org>, Alan Modra <amodra at gmail dot com>, nick clifton <nickc at redhat dot com>, Andreas Schwab <schwab at linux-m68k dot org>, binutils at sourceware dot org
- Date: Wed, 4 Apr 2012 13:13:38 +0000 (UTC)
- Subject: Re: [patch] ld: optimize vfinfo output slightly
- References: <201203240122.13385.vapier@gentoo.org> <201203301320.26204.vapier@gentoo.org> <20120331003048.GF12569@bubble.grove.modra.org> <201203302248.15411.vapier@gentoo.org> <mcrfwcp74cr.fsf@dhcp-172-18-216-180.mtv.corp.google.com>
On Fri, 30 Mar 2012, Ian Lance Taylor wrote:
> The warn_unused_result attribute in gcc was designed for the realloc
> function, where it is truly an error to ignore the result. It is
> absolutely not an error to ignore the result of fwrite; after all, it's
> perfectly reasonable to use ferror. It was a serious misunderstanding
> for anybody to attach the warn_unused_result attribute to fwrite. This
> misunderstanding was made even more serious by somebody deciding that it
> would be a good idea to have a compiler that defaults to defining
> _FORTIFY_SOURCE.
>
> So now we are in an absurd and painful situation, and there is no
> consensus on how to get out of it.
Test the patch attached to glibc bug 11959 with current sources, write a
ChangeLog entry for it and submit to libc-alpha to try to get consensus
there. I consider this to be a glibc bug that should be fixed in glibc.
(Once fixed in glibc, it would be reasonable for GCC to have a fixincludes
fix for the older buggy versions of glibc headers.)
--
Joseph S. Myers
joseph@codesourcery.com