Wireshark-dev: Re: [Wireshark-dev] Prevent compiler warnings by using "stop on warnings"/"treat

From: Richard van der Hoff <richardv@xxxxxxxxxxxxx>
Date: Tue, 20 Mar 2007 12:20:18 +0000
Ulf Lamping wrote:
I just meant that in the long run just ignoring a long list of warnings is probably not a good idea ...

However, disabling the signed warning, fix the rest and setting the "stop on error" barrier would still be a lot better than what we currently have ...

I heartily agree with Ulf on this - anything that you can do to reduce the number of warnings is a good thing.

Currently, you don't tend to even notice new warnings that you introduce on your own platform, as they get lost in the general compilation noise.

What needs to happen is a purge on as many warnings as possible, followed by turning on "treat warnings as errors". This can be done platform-by-platform if need be.

If you have to turn off the signed warning to make this viable, so be it - but it's there for a reason, and in general should be possible to fix properly rather than either just turning it off altogether, or casting away with a (void*).

Incidentally, if anyone knows the right knob to stop gcc accepting variable declarations in the middle of a block of code, it really needs turning on. I manage to mess this up almost every time I submit a patch...