Skip to content

Commit 9ab9a46

Browse files
committed
Add handle check for PhGetHandleInformation
1 parent c28356a commit 9ab9a46

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

phlib/hndlinfo.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1409,7 +1409,7 @@ NTSTATUS PhGetHandleInformationEx(
14091409
PPH_STRING objectName = NULL;
14101410
PPH_STRING bestObjectName = NULL;
14111411

1412-
if (Handle == NULL || Handle == NtCurrentProcess() || Handle == NtCurrentThread())
1412+
if (ProcessHandle == NULL || Handle == NULL || Handle == NtCurrentProcess() || Handle == NtCurrentThread())
14131413
return STATUS_INVALID_HANDLE;
14141414
if (ObjectTypeNumber != ULONG_MAX && ObjectTypeNumber >= MAX_OBJECT_TYPE_NUMBER)
14151415
return STATUS_INVALID_PARAMETER_3;

0 commit comments

Comments
 (0)