Re: [PATCH] Kbuild: Disable the -Wformat-security gcc flag

From: Sam Ravnborg
Date: Wed Feb 04 2009 - 17:13:19 EST


On Wed, Feb 04, 2009 at 03:28:47PM +0100, Floris Kraak wrote:
> Some distributions have enabled the gcc flag -Wformat-security by default.*
> This results in a number of warnings about format arguments to
> functions, sometimes in cases where fixing the warning is not likely
> to actually fix a bug.
> Instead of hand patching a dozens of places (possibly more) that
> produce warnings that get ignored anyway we just turn off the flag in
> the Makefile.
>
> Note: Regardless of any discussion surrounding the value of this
> particular type of warning, having this show up in a few distributions
> but not in the
> vast majority of them means that this warning won't be seen by most of
> the developers who introduce the new warnings in the first place. If
> the
> kernel decides it cares about format arguments it should do so
> globally regardless of distribution. In which case I'd gladly whip up
> a patch to do
> the reverse thing and turn this thing on by default. However, such a
> patch would have to produce a follow up patch(set) which fixes each
> individual
> warning.

Before judging on this patch could you please post what warning it
triggers and one or a few patches to fix some of them.

Sam
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/