mirror of https://github.com/x64dbg/GleeBug
I wonder how do you send the debugger a singlestepping exception. Added only two functions
This commit is contained in:
parent
6197f91790
commit
a1847472ba
|
|
@ -38,7 +38,17 @@ namespace GleeBug
|
|||
|
||||
void Debugger::exceptionEvent(EXCEPTION_DEBUG_INFO* exceptionInfo)
|
||||
{
|
||||
cbExceptionEvent(exceptionInfo);
|
||||
switch (exceptionInfo->ExceptionRecord.ExceptionCode){
|
||||
case EXCEPTION_SINGLE_STEP:
|
||||
cbException_single_spep(&exceptionInfo->ExceptionRecord);
|
||||
break;
|
||||
case EXCEPTION_BREAKPOINT:
|
||||
cbExcpetion_breakpoint(&exceptionInfo->ExceptionRecord);
|
||||
break;
|
||||
default:
|
||||
cbExceptionEvent(exceptionInfo);
|
||||
break;
|
||||
}
|
||||
}
|
||||
|
||||
void Debugger::debugStringEvent(OUTPUT_DEBUG_STRING_INFO* debugString)
|
||||
|
|
|
|||
|
|
@ -94,6 +94,18 @@ namespace GleeBug
|
|||
*/
|
||||
virtual void cbExceptionEvent(const EXCEPTION_DEBUG_INFO* exceptionInfo) {};
|
||||
|
||||
/*
|
||||
single step event
|
||||
these will execute instead of cbExceptionEvent.
|
||||
*/
|
||||
virtual void cbException_single_spep(EXCEPTION_RECORD* except_inf) {};
|
||||
|
||||
/*
|
||||
breakpoint event
|
||||
Will also execute instead of cbExceptionEvent.
|
||||
*/
|
||||
virtual void cbExcpetion_breakpoint(EXCEPTION_RECORD* except_inf) {};
|
||||
|
||||
/**
|
||||
\brief Debug string debug event callback. Provide an implementation to use this callback.
|
||||
\param debugString Information about the debug string.
|
||||
|
|
@ -117,6 +129,8 @@ namespace GleeBug
|
|||
virtual void debugStringEvent(OUTPUT_DEBUG_STRING_INFO* debugString);
|
||||
virtual void ripEvent(RIP_INFO* rip);
|
||||
|
||||
|
||||
|
||||
ProcessInfo _mainProcess;
|
||||
DWORD _continueStatus;
|
||||
bool _breakDebugger;
|
||||
|
|
|
|||
|
|
@ -21,6 +21,16 @@ protected:
|
|||
printf("Thread %d created with entry 0x%p\n", _debugEvent.dwThreadId, createThread->lpStartAddress);
|
||||
};
|
||||
|
||||
virtual void cbException_single_spep(EXCEPTION_RECORD* except_inf)
|
||||
{
|
||||
printf("a single step occurred at location 0x%X", except_inf->ExceptionAddress);
|
||||
};
|
||||
|
||||
virtual void cbExcpetion_breakpoint(EXCEPTION_RECORD* except_inf)
|
||||
{
|
||||
printf("a breakpoint occurred at location 0x%X", except_inf->ExceptionAddress);
|
||||
};
|
||||
|
||||
virtual void cbExitThreadEvent(const EXIT_THREAD_DEBUG_INFO* exitThread)
|
||||
{
|
||||
printf("Thread %d terminated with exit code 0x%08X\n", _debugEvent.dwThreadId, exitThread->dwExitCode);
|
||||
|
|
|
|||
Loading…
Reference in New Issue