[NTOS]: Bugfixes for the I/O Controller Object.

svn path=/trunk/; revision=49726
This commit is contained in:
Sir Richard 2010-11-23 16:32:56 +00:00
parent 49914debb9
commit 9dfdc0c94c

View file

@ -63,7 +63,11 @@ IoCreateController(IN ULONG Size)
PAGED_CODE();
/* Initialize an empty OBA */
InitializeObjectAttributes(&ObjectAttributes, NULL, 0, NULL, NULL);
InitializeObjectAttributes(&ObjectAttributes,
NULL,
OBJ_KERNEL_HANDLE,
NULL,
NULL);
/* Create the Object */
Status = ObCreateObject(KernelMode,
@ -87,7 +91,7 @@ IoCreateController(IN ULONG Size)
if (!NT_SUCCESS(Status)) return NULL;
/* Close the dummy handle */
NtClose(Handle);
ObCloseHandle(Handle, KernelMode);
/* Zero the Object and set its data */
RtlZeroMemory(Controller, sizeof(CONTROLLER_OBJECT) + Size);