[sane-devel] unpaper default parameter - empty output bug
Fri, 11 Mar 2005 17:38:42 -0500
On Fri, Mar 11, 2005 at 11:25:42PM +0100, Bertrik Sikken wrote:
> Try compiling it with compiler option --pedantic
> That results in lots of warnings, of which some look very suspicious.
> I' m not sure how big the stack is by default, but unpaper appears
> to put quite a lot of local variables on the stack
> (at least 140000 ints). Perhaps the stack overflows.
-O shouldn't affect stack usage much... -Wall -W --pedantic would
really turn the faucet on. -Werror will cause compilation to fail on
warnings (so it stops and you can see the reams of trouble that
gcc3 implements a brand new optimization architecture and is generally
far less tolerant of dodgy C code that was strictly illegal, but
generally worked in the past.
...or it's a bug that exists optimized and unoptimized, it's just that
optimization pushes the bug in one direction or the other so that it
suddenly becomes noticable.