From 9112fef1905363908e32477f09e6fdea5aacd9ab Mon Sep 17 00:00:00 2001 From: Hartmut Birr Date: Thu, 19 Aug 2004 21:56:17 +0000 Subject: [PATCH] - Fixed a crash which occurs on thread switching if the pde's for the new process structure are not established within the address space of the old thread. svn path=/trunk/; revision=10606 --- reactos/ntoskrnl/ps/thread.c | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/reactos/ntoskrnl/ps/thread.c b/reactos/ntoskrnl/ps/thread.c index 5595359ff20..48f964ad3ea 100644 --- a/reactos/ntoskrnl/ps/thread.c +++ b/reactos/ntoskrnl/ps/thread.c @@ -1,4 +1,4 @@ -/* $Id: thread.c,v 1.132 2004/08/15 16:39:10 chorns Exp $ +/* $Id: thread.c,v 1.133 2004/08/19 21:56:17 hbirr Exp $ * * COPYRIGHT: See COPYING in the top level directory * PROJECT: ReactOS kernel @@ -429,6 +429,9 @@ VOID PsDispatchThreadNoLock (ULONG NewThreadStatus) PiWakeupReaperThread(); } #endif + + MmUpdatePageDir(PsGetCurrentProcess(),(PVOID)CurrentThread->ThreadsProcess, sizeof(EPROCESS)); + KiArchContextSwitch(&CurrentThread->Tcb, &OldThread->Tcb); return; }