/* FUNCTIONS *****************************************************************/
VOID
-STDCALL
+NTAPI
DbgkCreateThread(PVOID StartAddress)
{
#if 0
- LPC_DBG_MESSAGE Message;
- LPC_DBG_MESSAGE Reply;
- NTSTATUS Status;
+ LPC_DBG_MESSAGE Message;
+ LPC_DBG_MESSAGE Reply;
+ NTSTATUS Status;
- if (PsGetCurrentThread()->ThreadsProcess->DebugPort == NULL)
+ if (PsGetCurrentThread()->ThreadsProcess->DebugPort == NULL)
{
- return;
+ return;
}
- Message.Header.MessageSize = sizeof(LPC_DBG_MESSAGE);
- Message.Header.DataSize = sizeof(LPC_DBG_MESSAGE) -
- sizeof(LPC_MESSAGE);
- Message.Type = DBG_EVENT_CREATE_THREAD;
- Message.Status = STATUS_SUCCESS;
- Message.Data.CreateThread.Reserved = 0;
- Message.Data.CreateThread.StartAddress = StartAddress;
-
- /* FIXME: Freeze all threads in process */
-
- /* Send the message to the process's debug port and wait for a reply */
- Status =
- LpcSendDebugMessagePort(PsGetCurrentThread()->ThreadsProcess->DebugPort,
- &Message,
- &Reply);
- if (!NT_SUCCESS(Status))
+ Message.Header.MessageSize = sizeof(LPC_DBG_MESSAGE);
+ Message.Header.DataSize = sizeof(LPC_DBG_MESSAGE) -
+ sizeof(LPC_MESSAGE);
+ Message.Type = DBG_EVENT_CREATE_THREAD;
+ Message.Status = STATUS_SUCCESS;
+ Message.Data.CreateThread.Reserved = 0;
+ Message.Data.CreateThread.StartAddress = StartAddress;
+
+ /* FIXME: Freeze all threads in process */
+
+ /* Send the message to the process's debug port and wait for a reply */
+ Status =
+ LpcSendDebugMessagePort(PsGetCurrentThread()->ThreadsProcess->DebugPort,
+ &Message,
+ &Reply);
+ if (!NT_SUCCESS(Status))
{
- return;
+ return;
}
- /* FIXME: Examine reply */
- return;
+ /* FIXME: Examine reply */
+ return;
#endif
}
/* FUNCTIONS *****************************************************************/
NTSTATUS
-STDCALL
+NTAPI
NtCreateDebugObject(OUT PHANDLE DebugHandle,
IN ACCESS_MASK DesiredAccess,
IN POBJECT_ATTRIBUTES ObjectAttributes,
}
NTSTATUS
-STDCALL
+NTAPI
NtWaitForDebugEvent(IN HANDLE DebugObject, // Debug object handle must grant DEBUG_OBJECT_WAIT_STATE_CHANGE access.
IN BOOLEAN Alertable,
IN PLARGE_INTEGER Timeout OPTIONAL,
}
NTSTATUS
-STDCALL
+NTAPI
NtDebugContinue(IN HANDLE DebugObject, // Debug object handle must grant DEBUG_OBJECT_WAIT_STATE_CHANGE access.
IN PCLIENT_ID AppClientId,
IN NTSTATUS ContinueStatus)
}
NTSTATUS
-STDCALL
+NTAPI
NtDebugActiveProcess(IN HANDLE Process, // Process handle must grant PROCESS_SUSPEND_RESUME access.
IN HANDLE DebugObject) // Debug object handle must grant DEBUG_OBJECT_ADD_REMOVE_PROCESS access.
{
}
NTSTATUS
-STDCALL
+NTAPI
NtRemoveProcessDebug(IN HANDLE Process, // Process handle must grant PROCESS_SUSPEND_RESUME access.
IN HANDLE DebugObject) // Debug object handle must grant DEBUG_OBJECT_ADD_REMOVE_PROCESS access.
{
}
NTSTATUS
-STDCALL
+NTAPI
NtSetInformationDebugObject(IN HANDLE DebugObject, // Debug object handle need not grant any particular access right.
IN DEBUGOBJECTINFOCLASS DebugObjectInformationClass,
IN PVOID DebugInformation,