First attempt on SEH usage; currently this does not take an effect due to missing exception dispatcher
All checks were successful
ci/woodpecker/push/build Pipeline was successful

This commit is contained in:
Rafal Kupiec 2023-02-26 22:08:02 +01:00
parent 2f1c5a22a5
commit 286fc76577
Signed by: belliash
GPG Key ID: 4E829243E0CFE6B4

View File

@ -124,8 +124,16 @@ KeInitializeThread(IN PKPROCESS Process,
Thread->StackBase = Stack;
Thread->StackLimit = Stack - KERNEL_STACK_SIZE;
__try
{
/* Initialize thread context */
KepInitializeThreadContext(Thread, SystemRoutine, StartRoutine, StartContext, Context);
}
__except(EXCEPTION_EXECUTE_HANDLER)
{
/* Failed to initialize thread context */
return STATUS_UNSUCCESSFUL;
}
/* Mark thread as initialized and run it */
Thread->State = Initialized;