Patrick
Patrick

Reputation: 23619

Application crashes in Visual Studio but only after a breakpoint has been set

My colleague has a very strange problem on his PC.

When he runs his application in the debugger (Visual Studio 2010) everything runs fine. But when he sets a breakpoint (anywhere, it doesn't matter where), and the breakpoint is hit, the next 'step' will raise an access violation in the application. We looked at the disassembly, and the address on which he complains is not accessed. If we step a second time, we see the 'violated address' on top of the call stack, although we don't see a call to it.

It looks like there is something overwriting the call stack, but apparently only after a breakpoint has been hit.

The PC has already been rebooted, but that didn't help. Any suggestions?

Upvotes: 3

Views: 2617

Answers (1)

Patrick
Patrick

Reputation: 23619

Found it.

In the Visual Studio options dialog "RPC Debugging" was enabled, which caused this strange behavior. Disabling it solved the problem.

Upvotes: 3

Related Questions