forked from xt-sys/exectos
Fix page fault on accessing initial thread frame
This commit is contained in:
parent
96a19d23b3
commit
0e6844e2fa
@ -43,7 +43,7 @@ KepInitializeThreadContext(IN PKTHREAD Thread,
|
|||||||
PFX_SAVE_FORMAT FxSaveFormat;
|
PFX_SAVE_FORMAT FxSaveFormat;
|
||||||
|
|
||||||
/* Set initial thread frame */
|
/* Set initial thread frame */
|
||||||
ThreadFrame = ((PKTHREAD_INIT_FRAME)Thread->InitialStack) - sizeof(KTHREAD_INIT_FRAME);
|
ThreadFrame = (PKTHREAD_INIT_FRAME)(Thread->InitialStack - sizeof(KTHREAD_INIT_FRAME));
|
||||||
|
|
||||||
/* Fill floating point save area with zeroes */
|
/* Fill floating point save area with zeroes */
|
||||||
RtlZeroMemory(&ThreadFrame->NpxFrame, sizeof(FX_SAVE_AREA));
|
RtlZeroMemory(&ThreadFrame->NpxFrame, sizeof(FX_SAVE_AREA));
|
||||||
|
Loading…
Reference in New Issue
Block a user