sizeof(ThreadInfo),
NULL);
if (!NT_SUCCESS(Status)) return Status;
- if (ThreadInfo == TRUE) return STATUS_THREAD_IS_TERMINATING;
+ if (ThreadInfo) return STATUS_THREAD_IS_TERMINATING;
/* Insert it into the Regular List */
InsertTailList(&Process->ThreadList, &Thread->Link);
{
UnProtectHandle(CsrThread->ThreadHandle);
Status = NtClose(CsrThread->ThreadHandle);
+
+ if (!NT_SUCCESS(Status))
+ DPRINT1("CSR: NtClose failed, we are going to ASSERT, Status = 0x%08lx; [0x%x, 0x%x] Process: 0x%p; ThreadHandle: 0x%p\n",
+ Status, CsrThread->ClientId.UniqueProcess, CsrThread->ClientId.UniqueThread, CsrProcess, CsrThread->ThreadHandle);
+
ASSERT(NT_SUCCESS(Status));
}
/* Get the Thread Create Time */
Status = NtQueryInformationThread(hThread,
ThreadTimes,
- (PVOID)&KernelTimes,
+ &KernelTimes,
sizeof(KernelTimes),
NULL);
if (!NT_SUCCESS(Status))