Developer forums (C::B DEVELOPMENT STRICTLY!) > Contributions to C::B

thanks for reply

(1/1)

zdai:
Thank you guys. The program in VC++ works well in windows OS. Many people are using it for several years. I have changed anything related to MFC, then compiled and built it in C::B IDE, no warning and no error. When I clicked "RUN" botton on tool bar of C::B IDE, several seconds later the program terminated without error, but the output was not correct. I debugged it step by step, the output was correct. It is that I said "works in debug mode, does not in release". Thanks again.

alchemist:
hello,

why don't you continue your first post?

thomas:
What you describe typically happens if you don't initialise a variable properly. Maybe in the "changed anything related to MFC" something like that happened.

The debugger initialises all variables to 0, so code like if(foo != 0) will work as expected in the debugger but will fail without it.

With some luck, the compiler will give you an appropriate warning if you compile with -Wall (although it does not detect it in every case). Otherwise, this can be a long, painful search.

Navigation

[0] Message Index

Go to full version