File tree Expand file tree Collapse file tree 1 file changed +2
-5
lines changed Expand file tree Collapse file tree 1 file changed +2
-5
lines changed Original file line number Diff line number Diff line change @@ -308,7 +308,7 @@ NTSTATUS PhEnumHandlesGeneric(
308
308
// * On Windows XP and later, NtQuerySystemInformation with SystemExtendedHandleInformation.
309
309
// * Otherwise, NtQuerySystemInformation with SystemHandleInformation can be used.
310
310
311
- if (KphIsConnected ())
311
+ if (KphIsConnected () && ProcessHandle )
312
312
{
313
313
PKPH_PROCESS_HANDLE_INFORMATION handles ;
314
314
PSYSTEM_HANDLE_INFORMATION_EX convertedHandles ;
@@ -344,7 +344,7 @@ NTSTATUS PhEnumHandlesGeneric(
344
344
}
345
345
}
346
346
347
- if (!NT_SUCCESS (status ) && WindowsVersion >= WINDOWS_8 && PhGetIntegerSetting (L"EnableHandleSnapshot" ))
347
+ if (!NT_SUCCESS (status ) && WindowsVersion >= WINDOWS_8 && ProcessHandle && PhGetIntegerSetting (L"EnableHandleSnapshot" ))
348
348
{
349
349
PPROCESS_HANDLE_SNAPSHOT_INFORMATION handles ;
350
350
PSYSTEM_HANDLE_INFORMATION_EX convertedHandles ;
@@ -451,9 +451,6 @@ VOID PhHandleProviderUpdate(
451
451
BOOLEAN useWorkQueue = FALSE;
452
452
PH_WORK_QUEUE workQueue ;
453
453
454
- if (!handleProvider -> ProcessHandle )
455
- goto UpdateExit ;
456
-
457
454
if (!NT_SUCCESS (handleProvider -> RunStatus = PhEnumHandlesGeneric (
458
455
handleProvider -> ProcessId ,
459
456
handleProvider -> ProcessHandle ,
You can’t perform that action at this time.
0 commit comments