From 24203ec76e83ddc416a8b3dc72f97f9faa0688ce Mon Sep 17 00:00:00 2001 From: Hartmut Birr Date: Sun, 14 Sep 2003 10:50:29 +0000 Subject: [PATCH] - Moved the call to ExpSwapThreadEventPair from PiDeleteThread to PsTerminateCurrentThread. svn path=/trunk/; revision=6076 --- reactos/ntoskrnl/ps/create.c | 4 +--- reactos/ntoskrnl/ps/kill.c | 4 +++- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/reactos/ntoskrnl/ps/create.c b/reactos/ntoskrnl/ps/create.c index bade8cc331d..9f4d3959fb5 100644 --- a/reactos/ntoskrnl/ps/create.c +++ b/reactos/ntoskrnl/ps/create.c @@ -1,4 +1,4 @@ -/* $Id: create.c,v 1.65 2003/09/10 06:12:22 vizzini Exp $ +/* $Id: create.c,v 1.66 2003/09/14 10:50:29 hbirr Exp $ * * COPYRIGHT: See COPYING in the top level directory * PROJECT: ReactOS kernel @@ -26,7 +26,6 @@ #include #include #include -#include #include #include #include @@ -312,7 +311,6 @@ PiDeleteThread(PVOID ObjectBody) PiNrThreads--; RemoveEntryList(&Thread->Tcb.ThreadListEntry); KeReleaseSpinLock(&PiThreadListLock, oldIrql); - ExpSwapThreadEventPair(Thread, NULL); /* Release the associated eventpair object, if there was one */ for (i = 0; i < NotifyRoutineCount; i++) { diff --git a/reactos/ntoskrnl/ps/kill.c b/reactos/ntoskrnl/ps/kill.c index 2cd2556444a..d8e339e579b 100644 --- a/reactos/ntoskrnl/ps/kill.c +++ b/reactos/ntoskrnl/ps/kill.c @@ -1,4 +1,4 @@ -/* $Id: kill.c,v 1.63 2003/08/18 11:23:32 hbirr Exp $ +/* $Id: kill.c,v 1.64 2003/09/14 10:50:29 hbirr Exp $ * * COPYRIGHT: See COPYING in the top level directory * PROJECT: ReactOS kernel @@ -12,6 +12,7 @@ /* INCLUDES *****************************************************************/ #include +#include #include #include #include @@ -189,6 +190,7 @@ PsTerminateCurrentThread(NTSTATUS ExitStatus) KeDispatcherObjectWake(&CurrentThread->Tcb.DispatcherHeader); KeReleaseDispatcherDatabaseLockAtDpcLevel(FALSE); + ExpSwapThreadEventPair(CurrentThread, NULL); /* Release the associated eventpair object, if there was one */ KeRemoveAllWaitsThread (CurrentThread, STATUS_UNSUCCESSFUL, FALSE); PsDispatchThreadNoLock(THREAD_STATE_TERMINATED_1);