Specify correct access rights in NtOpenProcess when sending control
events.
Modified: trunk/reactos/subsys/csrss/win32csr/conio.c
_____
Modified: trunk/reactos/subsys/csrss/win32csr/conio.c
--- trunk/reactos/subsys/csrss/win32csr/conio.c 2005-03-21 01:59:21 UTC
(rev 14248)
+++ trunk/reactos/subsys/csrss/win32csr/conio.c 2005-03-21 08:32:22 UTC
(rev 14249)
@@ -94,7 +94,8 @@
/* using OpenProcess is not optimal due to HANDLE vs. DWORD
PIDs... */
Status = NtOpenProcess(&Process,
- PROCESS_DUP_HANDLE,
+ PROCESS_DUP_HANDLE | PROCESS_VM_OPERATION
|
+ PROCESS_VM_WRITE | PROCESS_CREATE_THREAD,
&ObjectAttributes,
&ClientId);
if (!NT_SUCCESS(Status))
@@ -110,7 +111,7 @@
(PVOID) Event, 0, NULL);
if (NULL == Thread)
{
- DPRINT1("Failed thread creation\n");
+ DPRINT1("Failed thread creation (Error: 0x%x)\n",
GetLastError());
CloseHandle(Process);
return;
}
Show replies by date