P
pit3k
My program tries to call the vector:ush_back(...) member function in a
loop couple dozen milion times, which is what I expect.
After about 20 millions successfull push_back() calls the program
abnormally aborts with a core dump.
Investigation under debugger showed that this happens because the
internal vector's pointer was beeing decreased from about 0x40000000 to
0x00000009 and next push_back() call caused the core dump.
How am I supposed to detect such a situation in my program?
Can I made STL to throw an out of memory exception maybe?
loop couple dozen milion times, which is what I expect.
After about 20 millions successfull push_back() calls the program
abnormally aborts with a core dump.
Investigation under debugger showed that this happens because the
internal vector's pointer was beeing decreased from about 0x40000000 to
0x00000009 and next push_back() call caused the core dump.
How am I supposed to detect such a situation in my program?
Can I made STL to throw an out of memory exception maybe?