I'm experiencing a problem during debug with Microsoft Visual C++: wherever
I set a breakpoint (and even if I disable all breakpoints) the debugger
goes into disassembler mode, and it stops at the same line, returning a
dialog windows that says: "user breakpoint called from code at 0xXXXXXX".
The active module is NTDLL, the istruction is "int 3".
The odd thing is that if I open my code on another PC, it works fine, and so
does it if I launch it normally.
Can you help me? It's not very confortable working without the chance to use
the debug.
Most likely it's a sign of heap corruption (hard-coded breakpoint in ntdll.dll,
raised by Debug Win32 heap when it detects a corruption; debug heap is enabled
only when the application is started under debugger)
(check also the output in Debug Output window, may be there is an explanation
of the problem). It should be possible to tell more if you could post the call stack
at the moment of the exception, with good symbols for system DLLs.
You can also try to enable Full PageHeap and test the application with it:
HKLM\Software\Microsoft\Windows NT\CurrentVersion\Image File Execution
Options\YourApp.exe
GlobalFlag = REG_DWORD 0x2000000
PageHeapFlags = REG_DWORD 0x3
(replace YourApp.exe with the real name of your executable)
With these settings set in Registry, run the application under debugger,
and wait for access violations or hard-coded breakpoints, then check
the call stack to find the reason of the problem. Better if the application
is linked with release version of CRT library.
More information about PageHeap:
http://support.microsoft.com/default...b;en-us;286470
Regards,
Oleg
[VC++ MVP]