Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations strongm on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

OUT OF MEMORY in RELEASE VERSION but OK in DEBUG ??

Status
Not open for further replies.

youssef

Programmer
Mar 13, 2001
96
BE

Hi,

I complided my software in DEBUG and RELEASE mode all are OK.
But when I execute my RELEASE version, an error message appears " OUT OF MEMORY".

Anyone can help me for debbugging this error or how can I do for checking my memory when I execute my software.
 
It is probably an uninitialized variable. It may be that in the debug version, the default value is low but in the release version it is high.
 
What are you doing with pointers, if any? Make sure you have the appropriate deletes etc. If that is the case, check your new's where you dynamically allocate buffers. If you determine a number for allocation in your program and try to allocate a buffer too large then you could have problems. Make sure the calculated number is not returning an unsigned int and verify the return value when you get it back. Negative one can be quite large as an unsigned int :). Lastly, search on _DEBUG and make sure you are not doing thing in debug that you are not doing in release.

Matt
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top