CLIENT_ID ClientId;
/* If we don't have a PID, look it up */
- if (dwProcessId == -1) dwProcessId = (ULONG_PTR)CsrGetProcessId();
- if (dwProcessId == -1U) dwProcessId = (DWORD)CsrGetProcessId();
++ if (dwProcessId == -1U) dwProcessId = (DWORD_PTR)CsrGetProcessId();
/* Open a handle to the process */
ClientId.UniqueThread = NULL;
LONG RetValue;
HANDLE DebugPort = NULL;
NTSTATUS ErrCode;
- ULONG ErrorParameters[4];
+ ULONG_PTR ErrorParameters[4];
ULONG ErrorResponse;
- if (ExceptionInfo->ExceptionRecord->ExceptionCode == STATUS_ACCESS_VIOLATION &&
+ if ((NTSTATUS)ExceptionInfo->ExceptionRecord->ExceptionCode == STATUS_ACCESS_VIOLATION &&
ExceptionInfo->ExceptionRecord->NumberParameters >= 2)
{
switch(ExceptionInfo->ExceptionRecord->ExceptionInformation[0])
/* Save exception code and address */
ErrorParameters[0] = (ULONG)ExceptionInfo->ExceptionRecord->ExceptionCode;
- ErrorParameters[1] = (ULONG)ExceptionInfo->ExceptionRecord->ExceptionAddress;
+ ErrorParameters[1] = (ULONG_PTR)ExceptionInfo->ExceptionRecord->ExceptionAddress;
- if (ExceptionInfo->ExceptionRecord->ExceptionCode == STATUS_ACCESS_VIOLATION)
+ if ((NTSTATUS)ExceptionInfo->ExceptionRecord->ExceptionCode == STATUS_ACCESS_VIOLATION)
{
/* get the type of operation that caused the access violation */
ErrorParameters[2] = ExceptionInfo->ExceptionRecord->ExceptionInformation[0];