I was compiling today's svn, and noticed the following error:
G:\projects\codeblocks\src\plugins\debuggergdb\debuggergdb.cpp:951: warning: 'tgtIdx' might be used uninitialized in this function
The line is:
int tgtIdx = project->SelectTarget(tgtIdx);
It worries me. The SelectTarget uses as the parameter, an initialized value. How to handle this?
Quote from: rickg22 on May 25, 2007, 02:58:14 AM
int tgtIdx = project->SelectTarget(tgtIdx);
Yay, thats a bad one. I think it should be:
int tgtIdx = project->SelectTarget();
This will use the default value
-1 as initial target which is good since the requested build target is not valid (see line
949). Don't know who did that, but I suspect Yiannis... :twisted: ;-)
With regards, Morten.
Quote from: MortenMacFly on May 25, 2007, 07:55:45 AM
Quote from: rickg22 on May 25, 2007, 02:58:14 AM
int tgtIdx = project->SelectTarget(tgtIdx);
Yay, thats a bad one. I think it should be:
int tgtIdx = project->SelectTarget();
This will use the default value -1 as initial target which is good since the requested build target is not valid (see line 949). Don't know who did that, but I suspect Yiannis... :twisted: ;-)
With regards, Morten.
Don't suspect... be sure it was me :lol:.
Someone correct this please (sorry, my time is really limited atm).
Quote from: mandrav on May 25, 2007, 09:01:05 AM
Someone correct this please (sorry, my time is really limited atm).
Corrected. :)
Yay! I spotted a bug made by Yiannis! 8)
*Back in the saddle again...* :lol: