Exactly How Does My C++ Program Terminate When it Runs Out of Memory?
- by Jaime Melia
The following C++ program crashes on my Windows XP machine with a message "Abnormal program termination"
class Thing {};
int main()
{
for (;;) new Thing();
}
I would say it's an out of memory problem, except I'm not sure Windows gets near the limit. Is it Windows killing it on purpose? If so, how does it decide?