KdpStub

VOID __fastcall KdpStub(
        _KTRAP_FRAME *TrapFrame,
        _KEXCEPTION_FRAME *ExceptionFrame,
        _EXCEPTION_RECORD *ExceptionRecord,
        _CONTEXT *ContextRecord,
        CHAR PreviousMode,
        UINT8 SecondChance){
  unsigned __int64 v10; 
  INT64 v11; 

  if( ExceptionRecord->ExceptionCode == -2147483645
    && ExceptionRecord->NumberParameters
    && ((v10 = ExceptionRecord->ExceptionInformation[0], v10 - 3 <= 2) || v10 == 1) )
  {
    ++ContextRecord->_Rip;
  }
  else if( !KdPitchDebugger
         && KdAutoEnableOnEvent
         && KdPreviouslyEnabled
         && !(_BYTE)KdDebuggerEnabled
         && KdEnableDebugger() >= 0 )
  {
    if( (_BYTE)KdDebuggerEnabled )
      KdpTrap(
        TrapFrame,
        (_KTRAP_FRAME *)ExceptionFrame,
        ExceptionRecord,
        ContextRecord,
        PreviousMode,
        SecondChance,
        v11);
  }
}

Referenced by:

KdTrap