Archived

This topic is now archived and is closed to further replies.

qx452

release mode

Recommended Posts

I was using the LoadBitmapFile() function from OpenGL Game Programming and it was working fine in debug mode. I just tried release mode and it crashes. I put a lot of writing to the log in different places of the program and I found that it was crashing in the LoadBitmapFile() function. So I put a write to the log before almost every line in LoadBitmapFile() and it stopped crashing. Iv heard stories of peoples log code causing crashes but this is new my log code is stopping a crash! Any ideas why? Edited by - qx452 on December 17, 2001 5:10:17 PM

Share this post


Link to post
Share on other sites
Are you running the release build from the Release folder. It must be run from the main folder not the release folder otherwise the file names wont work and you will get an unhanded exception when you try to run it.

Share this post


Link to post
Share on other sites
Sounds to me like a buffer overrun. In debug mode MSVC protects all your variables and doesnt let your over-write the buffer. In release mode it doesnt do that and that can causes buffer overrun errors that dont appear in debug mode.

Make sure you arent writing to parts of an array that you didnt initialize!

For example.


Int array[5];

array[5] = 0;
array[6] = 0; etc...

Nitzan

-------------------------
www.geocities.com/nitzanw
www.scorchedearth3d.net
-------------------------

Share this post


Link to post
Share on other sites