Messages in this thread | | | Subject | Re: [PATCH] disable gcc warnings of sign/unsigned comparison | From | Trond Myklebust <> | Date | Thu, 01 Jan 2004 12:14:57 -0500 |
| |
På to , 01/01/2004 klokka 07:33, skreiv Paul Jackson: > This patch turns off all gcc warnings on comparing signed with unsigned > numbers, by setting the gcc option -Wno-sign-compare in the top > Makefile. >
Ignoring a potential bug is, of course one way of dealing with it. Most of us would prefer to deal with the bug itself, though.... A lot of effort has been put into coaxing gcc into detecting such comparison errors (see, for instance, the somewhat "unconventional" Linux min() and max() macros) precisely because signed comparisons have been a source of kernel bugs in the past...
How about therefore instead sending him a patch which fixes the actual code that is causing these warnings to be generated?
Cheers, Trond - To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html Please read the FAQ at http://www.tux.org/lkml/
| |