summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--psutil/arch/windows/process_info.c3
1 files changed, 1 insertions, 2 deletions
diff --git a/psutil/arch/windows/process_info.c b/psutil/arch/windows/process_info.c
index 62735728..5ea5f765 100644
--- a/psutil/arch/windows/process_info.c
+++ b/psutil/arch/windows/process_info.c
@@ -345,8 +345,7 @@ psutil_pid_is_running(DWORD pid) {
return 1;
if (pid < 0)
return 0;
- hProcess = OpenProcess(PROCESS_QUERY_INFORMATION | PROCESS_VM_READ,
- FALSE, pid);
+ hProcess = OpenProcess(PROCESS_QUERY_LIMITED_INFORMATION, FALSE, pid);
if (NULL == hProcess) {
err = GetLastError();
// Yeah, this is the actual error code in case of "no such process".