Definition at line 242 of file dbgkobj.c.
Referenced by DbgkCreateThread(), DbgkExitProcess(), DbgkExitThread(), DbgkForwardException(), DbgkMapViewOfSection(), and DbgkUnMapViewOfSection().
{
NTSTATUS Status;
BOOLEAN Suspended = FALSE;
PAGED_CODE();
DBGKTRACE(DBGK_MESSAGE_DEBUG, "ApiMsg: %p SuspendProcess: %lx\n", ApiMsg, SuspendProcess);
if (SuspendProcess) Suspended = DbgkpSuspendProcess();
ApiMsg->ReturnedStatus = STATUS_PENDING;
PspSetProcessFlag(PsGetCurrentProcess(), PSF_CREATE_REPORTED_BIT);
Status = DbgkpQueueMessage(PsGetCurrentProcess(),
PsGetCurrentThread(),
ApiMsg,
0,
NULL);
ZwFlushInstructionCache(NtCurrentProcess(), NULL, 0);
if (Suspended) DbgkpResumeProcess();
return Status;
}