I have a C++ app that will throw an exception when I try to single step from a breakpoint. For example:
1) Start app from VS2010 0 debugger is attached.
2) Set a breakpoint. It doesn't seem to matter where.
3) Do something in the app so that it hits the break point.
** VS2010 hits the break point
4) Single step the debugger to the next line of code.
VS2010 pops up a message box with this exception:
"Unhandled exception at 0x087df66f in SimpleGraphSDI.exe: 0xC0000005: Access violation."
Note that if I set a breakpoint on two consecutive lines of code, and press run to advance from one line to another, the app "runs" to the next line of code with no issues. The access violation is only when I use the single step command from VS2010.
Some code in the app has been around since VC6 and maybe earlier. However do not know if this is relevant.
UPDATE: The exception when single stepping the debugger does not occur if I start the app, and then attach the debugger after the app has started.