[torquedev] build error in current trunk

Steve Snelgrove ssnelgrove at clusterresources.com
Mon Apr 21 09:57:02 MDT 2008


Thanks for spotting this.  I have fixed this. I just realized why I am 
not seeing these errors.  It is because you have to have optimization 
turned on for all of the error checking to work.  I have this turned off 
for debugging with gdb.

:~/torque/t/src/server$ svn commit -m"Fixed uninitialized variable problem."
Sending        server/pbsd_main.c
Transmitting file data .
Committed revision 2092.



Chris Samuel wrote:
> Trying to verify the cpusets behaviour I just reported
> against the current trunk I got the following build error
> against r2091 of trunk:
>
> make[2]: Entering directory `/home/chris/Downloads/Linux/Torque/trunk/src/server'
> if gcc -DHAVE_CONFIG_H -I. -I. -I../../src/include  -I../../src/include  -DPBS_SERVER_HOME=\"/var/spool/torque\" -DPBS_ENVIRON=\"/var/spool/torque/pbs_environment\" -g -O2 -D_LARGEFILE64_SOURCE -W -Wall -Wno-unused-parameter -Wno-long-long -pedantic -Werror -MT pbsd_main.o -MD -MP -MF ".deps/pbsd_main.Tpo" -c -o pbsd_main.o pbsd_main.c; \
>         then mv -f ".deps/pbsd_main.Tpo" ".deps/pbsd_main.Po"; else rm -f ".deps/pbsd_main.Tpo"; exit 1; fi
> cc1: warnings being treated as errors
> pbsd_main.c: In function ‘main_loop’:
> pbsd_main.c:886: warning: ‘c’ may be used uninitialised in this function
> make[2]: *** [pbsd_main.o] Error 1
>
> Changing:
>
> int c;
>
> to:
>
> int c=0;
>
> fixes the compile (though I'm not sure if that's what
> is desired by whoever added it).
>
> cheers,
> Chris
>   



More information about the torquedev mailing list