mirror of
https://github.com/reactos/reactos.git
synced 2024-08-26 21:28:48 +00:00
[CSRSRV]: Try to see why it appears some processes don't have a handle in their CSR_PROCESS_DATA....
svn path=/trunk/; revision=53043
This commit is contained in:
parent
a2c84355ef
commit
5567f7d702
|
@ -105,6 +105,7 @@ PCSRSS_PROCESS_DATA WINAPI CsrCreateProcessData(HANDLE ProcessId)
|
||||||
PROCESS_ALL_ACCESS,
|
PROCESS_ALL_ACCESS,
|
||||||
&ObjectAttributes,
|
&ObjectAttributes,
|
||||||
&ClientId);
|
&ClientId);
|
||||||
|
DPRINT1("CSR PRocess: %p Handle: %p\n", pProcessData, pProcessData->Process);
|
||||||
if (!NT_SUCCESS(Status))
|
if (!NT_SUCCESS(Status))
|
||||||
{
|
{
|
||||||
ProcessData[hash] = pProcessData->next;
|
ProcessData[hash] = pProcessData->next;
|
||||||
|
|
|
@ -282,6 +282,7 @@ CsrSrvAttachSharedSection(IN PCSRSS_PROCESS_DATA CsrProcess OPTIONAL,
|
||||||
if (CsrProcess)
|
if (CsrProcess)
|
||||||
{
|
{
|
||||||
/* Map the sectio into this process */
|
/* Map the sectio into this process */
|
||||||
|
DPRINT1("CSR Process Handle: %p. CSR Process: %p\n", CsrProcess->Process, CsrProcess);
|
||||||
Status = NtMapViewOfSection(CsrSrvSharedSection,
|
Status = NtMapViewOfSection(CsrSrvSharedSection,
|
||||||
CsrProcess->Process,
|
CsrProcess->Process,
|
||||||
&CsrSrvSharedSectionBase,
|
&CsrSrvSharedSectionBase,
|
||||||
|
@ -439,6 +440,24 @@ CsrpHandleConnectionRequest (PPORT_MESSAGE Request,
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
if (ProcessData->Process == NULL)
|
||||||
|
{
|
||||||
|
OBJECT_ATTRIBUTES ObjectAttributes;
|
||||||
|
|
||||||
|
InitializeObjectAttributes(&ObjectAttributes,
|
||||||
|
NULL,
|
||||||
|
0,
|
||||||
|
NULL,
|
||||||
|
NULL);
|
||||||
|
DPRINT1("WARNING: CSR PROCESS WITH NO CSR PROCESS HANDLE???\n");
|
||||||
|
ClientId.UniqueThread = 0;
|
||||||
|
Status = NtOpenProcess(&ProcessData->Process,
|
||||||
|
PROCESS_ALL_ACCESS,
|
||||||
|
&ObjectAttributes,
|
||||||
|
&Request->ClientId);
|
||||||
|
DPRINT1("Status: %lx. Handle: %lx\n", Status, ProcessData->Process);
|
||||||
|
}
|
||||||
|
|
||||||
if (ProcessData)
|
if (ProcessData)
|
||||||
{
|
{
|
||||||
/* Attach the Shared Section */
|
/* Attach the Shared Section */
|
||||||
|
|
Loading…
Reference in a new issue