locked
breakpoint hit with custom debugger RRS feed

  • Question

  •  I am trying to simulate a  break point hit on a text file with a custom debug engine. On firing the breakpoint hit, debugger seems to recognize the break point , gets the breakpoint window updated (marks the hit breakpoint in bold and changes width) . debugger goes into stop mode but the breakpoint image doesn't show the arrow marker.
    Any pointers what could be wrong in this case
    Thanks
    Tuesday, June 17, 2008 4:36 PM

Answers

  •  I have dealt with this problem in the past and there were several things that had to be done before the arrow would display. 

    1.  The OnModuleLoad event sent to the SDM.
    2.  The OnLoadComplete event sent to the SDM.
    3.  The OnBreakpoint event sent to the SDM.

    After those 3 events are sent the SDM should call your class implementing the IDebugStackFrame2 interface.  I think the FrameInfo structure that is filled in by the GetInfo method determines where the yellow arrow is placed.  I would check to make sure that method is getting called and is working correctly.

    I hope this helps.

    Ben
    • Proposed as answer by Feng Chen Wednesday, June 18, 2008 11:53 AM
    • Marked as answer by Feng Chen Friday, June 20, 2008 3:38 AM
    Tuesday, June 17, 2008 9:53 PM
  • bmorrison is correct. The top stack frame returned from IDebugThread2::EnumStackFrames must return a valid document context or the arrow will not be displayed.

    Jackson
    • Proposed as answer by Feng Chen Wednesday, June 18, 2008 11:53 AM
    • Marked as answer by Feng Chen Friday, June 20, 2008 3:38 AM
    Tuesday, June 17, 2008 11:05 PM

All replies

  •  I have dealt with this problem in the past and there were several things that had to be done before the arrow would display. 

    1.  The OnModuleLoad event sent to the SDM.
    2.  The OnLoadComplete event sent to the SDM.
    3.  The OnBreakpoint event sent to the SDM.

    After those 3 events are sent the SDM should call your class implementing the IDebugStackFrame2 interface.  I think the FrameInfo structure that is filled in by the GetInfo method determines where the yellow arrow is placed.  I would check to make sure that method is getting called and is working correctly.

    I hope this helps.

    Ben
    • Proposed as answer by Feng Chen Wednesday, June 18, 2008 11:53 AM
    • Marked as answer by Feng Chen Friday, June 20, 2008 3:38 AM
    Tuesday, June 17, 2008 9:53 PM
  • bmorrison is correct. The top stack frame returned from IDebugThread2::EnumStackFrames must return a valid document context or the arrow will not be displayed.

    Jackson
    • Proposed as answer by Feng Chen Wednesday, June 18, 2008 11:53 AM
    • Marked as answer by Feng Chen Friday, June 20, 2008 3:38 AM
    Tuesday, June 17, 2008 11:05 PM