Link to home
Start Free TrialLog in
Avatar of _versamps_
_versamps_

asked on

out of memory

Ive been working on a program for the last year working fine. I jsut made a change to it and now when I try to run it in debug mode i get an error saying 'Out of memory'. if i fix where it crashes it will just happen further on in execution. I have restarted the computer and only have vc6.0 running. no other programs. need help urgently
Avatar of PlanetCpp
PlanetCpp

and whats the change you just made??
Avatar of _versamps_

ASKER

i added a cstatic and a cedit to the dialog and removed a button.
i don't know its really just not enough information. i don't use dialogs either which makes it harder to think of what it can be.
ye problem is that it happens within different sections(dlls) within my main project. i fixed it from one area where i try to anchor a edit box then once i fixed the 'out of memory' there it crashed on a CArchive.Serialize call in a totally different dll. Im beginning to think my compiler has gone up the creek.
ASKER CERTIFIED SOLUTION
Avatar of WaffleSouffle
WaffleSouffle

Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial
Basically you get Out of Memory when you allocate to much resources and you don't release them.
for example if you keep allocating a pointer and you don't release it you will end up with this error:
while(true)
{
     int *p = new int(1);
}

So check those nasty pointers.
in my view, could be many reasons..
1. are u using the debug mode dlls?
2. any recursion without an end condition?
???

dunnooooo
nah no recursion... the error message says only "Out Of Memory". thats it. i thought it maybe something to do with ID's but not so sure if its now crashing on a Serialize call. im using it in Debug.. if i try release mode i just get an exception instead of the Out Of Memory message
had something to do with the ID's. thanks
Great - who gets the points nudge nudge
Great - who gets the points nudge nudge
oops thort i did that already. it happens still every now and again which i believe a file must be corrupt sumwhere. neways thanks