Fix previous strangely incomplete NtRaiseException implementation and re-enable the ProbeForRead call that failed Modified: trunk/reactos/ntoskrnl/ke/exception.c Modified: trunk/reactos/ntoskrnl/ke/i386/exp.c Modified: trunk/reactos/ntoskrnl/ke/i386/syscall.S _____
Modified: trunk/reactos/ntoskrnl/ke/exception.c --- trunk/reactos/ntoskrnl/ke/exception.c 2005-09-12 03:10:08 UTC (rev 17815) +++ trunk/reactos/ntoskrnl/ke/exception.c 2005-09-12 03:59:03 UTC (rev 17816) @@ -23,7 +23,7 @@
CONTEXT LocalContext;
/* We'll have to make a copy and probe it */ - //ProbeForRead(Context, sizeof(CONTEXT), sizeof(ULONG)); + ProbeForRead(Context, sizeof(CONTEXT), sizeof(ULONG)); RtlMoveMemory(&LocalContext, Context, sizeof(CONTEXT)); Context = &LocalContext;
_____
Modified: trunk/reactos/ntoskrnl/ke/i386/exp.c --- trunk/reactos/ntoskrnl/ke/i386/exp.c 2005-09-12 03:10:08 UTC (rev 17815) +++ trunk/reactos/ntoskrnl/ke/i386/exp.c 2005-09-12 03:59:03 UTC (rev 17816) @@ -1017,6 +1017,7 @@
/* Align context size and get stack pointer */ Size = (sizeof(CONTEXT) + 3) & ~3; Stack = (Context.Esp & ~3) - Size; + DPRINT1("Stack: %lx\n", Stack);
/* Probe stack and copy Context */ ProbeForWrite((PVOID)Stack, Size, sizeof(ULONG)); @@ -1027,6 +1028,7 @@ (EXCEPTION_MAXIMUM_PARAMETERS - ExceptionRecord->NumberParameters) * sizeof(ULONG) + 3) & ~3; NewStack = Stack - Size; + DPRINT1("NewStack: %lx\n", NewStack);
/* Probe stack and copy exception record. Don't forget to add the two params */ ProbeForWrite((PVOID)(NewStack - 2 * sizeof(ULONG_PTR)), _____
Modified: trunk/reactos/ntoskrnl/ke/i386/syscall.S --- trunk/reactos/ntoskrnl/ke/i386/syscall.S 2005-09-12 03:10:08 UTC (rev 17815) +++ trunk/reactos/ntoskrnl/ke/i386/syscall.S 2005-09-12 03:59:03 UTC (rev 17816) @@ -498,6 +498,13 @@
pop ebp mov esp, ebp
+ /* Check the result */ + or eax, eax + jz _KiServiceExit2 + + /* Restore debug registers too */ + jmp _KiServiceExit + .globl _NtContinue@8 _NtContinue@8: