mirror of
https://github.com/reactos/reactos.git
synced 2024-12-28 01:55:19 +00:00
Move removing process from active list to PspDeleteProcess instead of PspExitProcess. This way we don't have to do it manually after ObInsertObject failure in PspCreateProces. Also, set the Process Query Time at the end of Process Creation, since the process doesn't really exist before then. Thanks to Hartmut for finding the bugs.
svn path=/trunk/; revision=14778
This commit is contained in:
parent
e60561fb17
commit
6c66ab6c64
1 changed files with 6 additions and 6 deletions
|
@ -148,6 +148,11 @@ PspDeleteProcess(PVOID ObjectBody)
|
|||
|
||||
DPRINT("PiDeleteProcess(ObjectBody %x)\n", ObjectBody);
|
||||
|
||||
/* Remove it from the Active List */
|
||||
ExAcquireFastMutex(&PspActiveProcessMutex);
|
||||
RemoveEntryList(&Process->ProcessListEntry);
|
||||
ExReleaseFastMutex(&PspActiveProcessMutex);
|
||||
|
||||
/* Delete the CID Handle */
|
||||
if(Process->UniqueProcessId != NULL) {
|
||||
|
||||
|
@ -411,12 +416,7 @@ PspExitProcess(PEPROCESS Process)
|
|||
DPRINT("PspExitProcess 0x%x\n", Process);
|
||||
|
||||
PspRunCreateProcessNotifyRoutines(Process, FALSE);
|
||||
|
||||
/* Remove it from the Active List */
|
||||
ExAcquireFastMutex(&PspActiveProcessMutex);
|
||||
RemoveEntryList(&Process->ProcessListEntry);
|
||||
ExReleaseFastMutex(&PspActiveProcessMutex);
|
||||
|
||||
|
||||
/* close all handles associated with our process, this needs to be done
|
||||
when the last thread still runs */
|
||||
ObKillProcess(Process);
|
||||
|
|
Loading…
Reference in a new issue