mirror of
https://github.com/reactos/reactos.git
synced 2025-04-09 23:37:40 +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 bus.
svn path=/trunk/; revision=14777
This commit is contained in:
parent
efa3efe5bb
commit
e60561fb17
1 changed files with 3 additions and 5 deletions
|
@ -287,8 +287,6 @@ PspCreateProcess(OUT PHANDLE ProcessHandle,
|
|||
/* Clean up the Object */
|
||||
DPRINT("Cleaning Process Object\n");
|
||||
RtlZeroMemory(Process, sizeof(EPROCESS));
|
||||
|
||||
KeQuerySystemTime(&Process->CreateTime);
|
||||
|
||||
/* Inherit stuff from the Parent since we now have the object created */
|
||||
if (pParentProcess)
|
||||
|
@ -411,13 +409,13 @@ PspCreateProcess(OUT PHANDLE ProcessHandle,
|
|||
if (!NT_SUCCESS(Status))
|
||||
{
|
||||
DPRINT1("Could not get a handle to the Process Object\n");
|
||||
ExAcquireFastMutex(&PspActiveProcessMutex);
|
||||
RemoveEntryList(&Process->ProcessListEntry);
|
||||
ExReleaseFastMutex(&PspActiveProcessMutex);
|
||||
ObDereferenceObject(Process);
|
||||
goto exitdereferenceobjects;
|
||||
}
|
||||
|
||||
/* Set the Creation Time */
|
||||
KeQuerySystemTime(&Process->CreateTime);
|
||||
|
||||
DPRINT("Done. Returning handle: %x\n", hProcess);
|
||||
_SEH_TRY
|
||||
{
|
||||
|
|
Loading…
Reference in a new issue