mysqldd.c(353) : warning C4701: potentially uninitialized local variable 'pFieldInfo' used

This should not be a problem, since pFieldInfo.uiType is uninitialiased only if previous switch() sentence uses default clause. But in this case bError is TRUE, and switch( pFieldInfo.uiType ) is not executed at all.
We may pacify MSVC by adding
  pFieldInfo.uiType = 0;
to default clause of before the first switch(). Please test if this helps.

Yes, it does the trick.

BTW, I see you've found a lot of unused variables in my code using MSVC. BCC55 also has this warning, but it is switched off by default. Sometimes I think that adding "-wuse" command line option will be a good thing.

We use -w, which turns on all warnings. I'm specifically
getting this kind of warnings in DEBUG mode for some
BCC 5.8 internal variable. It's not the same as
"potentially uninitialized" though.

In my experience MSVS is very good at signaling warnings,
while BCC is very forgiving, sometimes even buggy in
5.8.

Brgds,
Viktor

_______________________________________________
Harbour mailing list
Harbour@harbour-project.org
http://lists.harbour-project.org/mailman/listinfo/harbour

Reply via email to