VC++ Debugging
Hi, i'm debugging a program and in the middle of the program i get a messege that i wrote too much (overwrote) into a std vector. it told me that the error occured on line 757 of the vector.h file. is there any way to know were it happened in the program - ie: what vector was overwritten?
Thanks.
Run the code in the debugger, when it asserts, look at the call stack window.
http://msdn2.microsoft.com/en-us/library/a3694ts5.aspx
http://msdn2.microsoft.com/en-us/library/a3694ts5.aspx
Thanks, but how to i get the call stack window? I went to Debug->Windows on the menu and didn't see anything. i also couldn't find it in Tools->Import and Export Settings.
Thanks.
Thanks.
In VC2005 It's at Debug->Windows->Call Stack. The menu is basically split into 4 sections, Call Stack is at the top of the third section. You can also do Ctrl-Alt-C.
Once you see the stack you can double click any function to jump to it and look at locals, etc.
Once you see the stack you can double click any function to jump to it and look at locals, etc.
The "Call Stack" item only appears on the Debug -> Windows menu when you're in a debugging session (i.e. Debug -> Start Debugging) and the call stack window only contains anything when your program is stopped in the debugger as the result of an unhandled exception, hitting a breakpoint, or being stopped through code such as happens when you choose to 'debug' when you get an assert.
This topic is closed to new replies.
Advertisement
Popular Topics
Advertisement