News:

Accounts with zero posts and zero activity during the last months will be deleted periodically to fight SPAM!

Main Menu

Code is not running when run, but running fine in the debug mode

Started by e-nnovation, March 07, 2010, 08:01:27 PM

Previous topic - Next topic

e-nnovation

Hi Everyone,

When I run my code, it is giving the following error
Process terminated with status -1073741510

But when I set the breakpoint at the last statement of the main function, I am able to see the expected output.
Am new to code blocks. So any info in this regard would be great.

Thank you in advance.

Details that you may require:
1. code is completely written in c (only one source file, main.c)
2. am running code blocks 8.02 on vista.
3. used gnu gcc compiler

stahta01

Best guess; upgrade the compiler if the compiler was the one packaged with Code::Blocks 8.02.

If not, please state compiler version.

The command gcc -v

gcc -v


Gives the last one of this below. Many lines in front of this line.

gcc version 3.4.5 (mingw-vista special r3)


Note: (mingw-vista special r2) did NOT work well under Vista.

Edit: The normal answer for your question "work in debug; not in release" is that the code is likely wrong.
Normally, the cause is failure to initial a variable; but, with large code project the cause can be many things. But, running the old MinGW GCC under Vista has given different results for different users/computers; so, I said that first.

Tim S.
C Programmer working to learn more about C++.
On Windows 10 64 bit and Windows 11 64 bit.
--
When in doubt, read the CB WiKi FAQ. [url="http://wiki.codeblocks.org"]http://wiki.codeblocks.org[/url]