[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]
Re: Bootstrap problem with current
On 07/11/17 15:48, Joerg Sonnenberger wrote:
On Tue, Jul 11, 2017 at 03:07:24PM -0500, Jason Bacon wrote:
I think it's reasonable for an optional security feature like FORTIFY_SOURCE
to throw a warning for ignoring the return value of an I/O function that
might fail and leave a corrupted output file, so I would not say the headers
The point is that error checking for stdio functions is normally done
using ferror() and feof(). That's exactly what fixup-libtool.c does.
Insisting on checking each call is just useless, especially since
buffering makes the error checking useless in most cases.
I agree that ferror() and feof() are sufficient for error checking if
used correctly, but GCC is only throwing a warning, not an error, and
only if the user deliberately requests it with -D_FORTIFY_SOURCE. I
think this is reasonable behavior on the part of RHEL/GCC.
I prefer to have things like this flagged during compilation. I
generally aim for a clean compile with -Wall, but I don't mind ignoring
a few warnings from FORTIFY_SOURCE, lint, etc.
Earth is a beta site.
Main Index |
Thread Index |