mirror of
https://github.com/reactos/reactos.git
synced 2025-08-05 09:03:25 +00:00
Use correct format for arguments in debug messages
svn path=/trunk/; revision=19990
This commit is contained in:
parent
20f8a4d7f6
commit
ab0692d3c7
3 changed files with 33 additions and 33 deletions
|
@ -67,7 +67,7 @@ CsrClientCallServer(PCSR_API_MESSAGE ApiMessage,
|
||||||
//ApiMessage->Opcode = ApiNumber; <- Activate with new CSR
|
//ApiMessage->Opcode = ApiNumber; <- Activate with new CSR
|
||||||
ApiMessage->CsrCaptureData = NULL;
|
ApiMessage->CsrCaptureData = NULL;
|
||||||
|
|
||||||
DPRINT("API: %x, u1.s1.DataLength: %x, u1.s1.TotalLength: %x\n",
|
DPRINT("API: %lx, u1.s1.DataLength: %x, u1.s1.TotalLength: %x\n",
|
||||||
ApiNumber,
|
ApiNumber,
|
||||||
ApiMessage->Header.u1.s1.DataLength,
|
ApiMessage->Header.u1.s1.DataLength,
|
||||||
ApiMessage->Header.u1.s1.TotalLength);
|
ApiMessage->Header.u1.s1.TotalLength);
|
||||||
|
@ -94,15 +94,15 @@ CsrClientCallServer(PCSR_API_MESSAGE ApiMessage,
|
||||||
while (PointerCount--)
|
while (PointerCount--)
|
||||||
{
|
{
|
||||||
/* Get this pointer and check if it's valid */
|
/* Get this pointer and check if it's valid */
|
||||||
DPRINT("Array Address: %p. This pointer: %p. Data: %p\n",
|
DPRINT("Array Address: %p. This pointer: %p. Data: %lx\n",
|
||||||
&Pointers, Pointers, *Pointers);
|
&Pointers, Pointers, *Pointers);
|
||||||
if ((CurrentPointer = *Pointers++))
|
if ((CurrentPointer = *Pointers++))
|
||||||
{
|
{
|
||||||
/* Update it */
|
/* Update it */
|
||||||
DPRINT("CurrentPointer: %p.\n", *(PULONG_PTR)CurrentPointer);
|
DPRINT("CurrentPointer: %lx.\n", *(PULONG_PTR)CurrentPointer);
|
||||||
*(PULONG_PTR)CurrentPointer += CsrPortMemoryDelta;
|
*(PULONG_PTR)CurrentPointer += CsrPortMemoryDelta;
|
||||||
Pointers[-1] = CurrentPointer - (ULONG_PTR)ApiMessage;
|
Pointers[-1] = CurrentPointer - (ULONG_PTR)ApiMessage;
|
||||||
DPRINT("CurrentPointer: %p.\n", *(PULONG_PTR)CurrentPointer);
|
DPRINT("CurrentPointer: %lx.\n", *(PULONG_PTR)CurrentPointer);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -164,7 +164,7 @@ CsrClientCallServer(PCSR_API_MESSAGE ApiMessage,
|
||||||
}
|
}
|
||||||
|
|
||||||
/* Return the CSR Result */
|
/* Return the CSR Result */
|
||||||
DPRINT("Got back: %x\n", ApiMessage->Status);
|
DPRINT("Got back: 0x%lx\n", ApiMessage->Status);
|
||||||
return ApiMessage->Status;
|
return ApiMessage->Status;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -433,7 +433,7 @@ CsrClientConnectToServer(PWSTR ObjectDirectory,
|
||||||
}
|
}
|
||||||
|
|
||||||
/* Let the caller know if this was server to server */
|
/* Let the caller know if this was server to server */
|
||||||
DPRINT("Status was: %lx. Are we in server: %lx\n", Status, InsideCsrProcess);
|
DPRINT("Status was: 0x%lx. Are we in server: 0x%x\n", Status, InsideCsrProcess);
|
||||||
if (ServerToServerCall) *ServerToServerCall = InsideCsrProcess;
|
if (ServerToServerCall) *ServerToServerCall = InsideCsrProcess;
|
||||||
return Status;
|
return Status;
|
||||||
}
|
}
|
||||||
|
|
|
@ -110,7 +110,7 @@ LoadImageFileExecutionOptions(PPEB Peb)
|
||||||
if (NT_SUCCESS(Status))
|
if (NT_SUCCESS(Status))
|
||||||
{
|
{
|
||||||
Peb->NtGlobalFlag |= Value;
|
Peb->NtGlobalFlag |= Value;
|
||||||
DPRINT("GlobalFlag: Key='%S', Value=%08x\n", ValueBuffer, Value);
|
DPRINT("GlobalFlag: Key='%S', Value=0x%lx\n", ValueBuffer, Value);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
/*
|
/*
|
||||||
|
@ -260,9 +260,9 @@ LdrpInit(PCONTEXT Context,
|
||||||
if (NtCurrentPeb()->Ldr == NULL || NtCurrentPeb()->Ldr->Initialized == FALSE)
|
if (NtCurrentPeb()->Ldr == NULL || NtCurrentPeb()->Ldr->Initialized == FALSE)
|
||||||
{
|
{
|
||||||
Peb = NtCurrentPeb();
|
Peb = NtCurrentPeb();
|
||||||
DPRINT("Peb %x\n", Peb);
|
DPRINT("Peb %p\n", Peb);
|
||||||
ImageBase = Peb->ImageBaseAddress;
|
ImageBase = Peb->ImageBaseAddress;
|
||||||
DPRINT("ImageBase %x\n", ImageBase);
|
DPRINT("ImageBase %p\n", ImageBase);
|
||||||
if (ImageBase <= (PVOID)0x1000)
|
if (ImageBase <= (PVOID)0x1000)
|
||||||
{
|
{
|
||||||
DPRINT("ImageBase is null\n");
|
DPRINT("ImageBase is null\n");
|
||||||
|
@ -271,7 +271,7 @@ LdrpInit(PCONTEXT Context,
|
||||||
|
|
||||||
/* If MZ header exists */
|
/* If MZ header exists */
|
||||||
PEDosHeader = (PIMAGE_DOS_HEADER) ImageBase;
|
PEDosHeader = (PIMAGE_DOS_HEADER) ImageBase;
|
||||||
DPRINT("PEDosHeader %x\n", PEDosHeader);
|
DPRINT("PEDosHeader %p\n", PEDosHeader);
|
||||||
|
|
||||||
if (PEDosHeader->e_magic != IMAGE_DOS_SIGNATURE ||
|
if (PEDosHeader->e_magic != IMAGE_DOS_SIGNATURE ||
|
||||||
PEDosHeader->e_lfanew == 0L ||
|
PEDosHeader->e_lfanew == 0L ||
|
||||||
|
|
|
@ -534,7 +534,7 @@ LdrpMapKnownDll(IN PUNICODE_STRING DllName,
|
||||||
&ObjectAttributes);
|
&ObjectAttributes);
|
||||||
if (!NT_SUCCESS(Status))
|
if (!NT_SUCCESS(Status))
|
||||||
{
|
{
|
||||||
DPRINT("NtOpenSection() failed for '%wZ' (Status %lx)\n", DllName, Status);
|
DPRINT("NtOpenSection() failed for '%wZ' (Status 0x%08lx)\n", DllName, Status);
|
||||||
return Status;
|
return Status;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -639,7 +639,7 @@ LdrpMapDllImageFile(IN PWSTR SearchPath OPTIONAL,
|
||||||
FILE_SYNCHRONOUS_IO_NONALERT);
|
FILE_SYNCHRONOUS_IO_NONALERT);
|
||||||
if (!NT_SUCCESS(Status))
|
if (!NT_SUCCESS(Status))
|
||||||
{
|
{
|
||||||
DPRINT1("Dll open of %wZ failed: Status = 0x%08x\n",
|
DPRINT1("Dll open of %wZ failed: Status = 0x%08lx\n",
|
||||||
&FullNtFileName, Status);
|
&FullNtFileName, Status);
|
||||||
RtlFreeUnicodeString (&FullNtFileName);
|
RtlFreeUnicodeString (&FullNtFileName);
|
||||||
return Status;
|
return Status;
|
||||||
|
@ -657,7 +657,7 @@ LdrpMapDllImageFile(IN PWSTR SearchPath OPTIONAL,
|
||||||
NULL);
|
NULL);
|
||||||
if (!NT_SUCCESS(Status))
|
if (!NT_SUCCESS(Status))
|
||||||
{
|
{
|
||||||
DPRINT("Dll header read failed: Status = 0x%08x\n", Status);
|
DPRINT("Dll header read failed: Status = 0x%08lx\n", Status);
|
||||||
NtClose(FileHandle);
|
NtClose(FileHandle);
|
||||||
return Status;
|
return Status;
|
||||||
}
|
}
|
||||||
|
@ -694,7 +694,7 @@ LdrpMapDllImageFile(IN PWSTR SearchPath OPTIONAL,
|
||||||
|
|
||||||
if (!NT_SUCCESS(Status))
|
if (!NT_SUCCESS(Status))
|
||||||
{
|
{
|
||||||
DPRINT("NTDLL create section failed: Status = 0x%08x\n", Status);
|
DPRINT("NTDLL create section failed: Status = 0x%08lx\n", Status);
|
||||||
return Status;
|
return Status;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -1031,7 +1031,7 @@ LdrGetExportByOrdinal (
|
||||||
ExportDir->AddressOfFunctions
|
ExportDir->AddressOfFunctions
|
||||||
);
|
);
|
||||||
DPRINT(
|
DPRINT(
|
||||||
"LdrGetExportByOrdinal(Ordinal %d) = %p\n",
|
"LdrGetExportByOrdinal(Ordinal %lu) = %p\n",
|
||||||
Ordinal,
|
Ordinal,
|
||||||
RVA(BaseAddress, ExFunctions[Ordinal - ExportDir->Base] )
|
RVA(BaseAddress, ExFunctions[Ordinal - ExportDir->Base] )
|
||||||
);
|
);
|
||||||
|
@ -1083,7 +1083,7 @@ LdrGetExportByName(PVOID BaseAddress,
|
||||||
LONG minn, maxn;
|
LONG minn, maxn;
|
||||||
ULONG ExportDirSize;
|
ULONG ExportDirSize;
|
||||||
|
|
||||||
DPRINT("LdrGetExportByName %x %s %hu\n", BaseAddress, SymbolName, Hint);
|
DPRINT("LdrGetExportByName %p %s %hu\n", BaseAddress, SymbolName, Hint);
|
||||||
|
|
||||||
ExportDir = (PIMAGE_EXPORT_DIRECTORY)
|
ExportDir = (PIMAGE_EXPORT_DIRECTORY)
|
||||||
RtlImageDirectoryEntryToData(BaseAddress,
|
RtlImageDirectoryEntryToData(BaseAddress,
|
||||||
|
@ -1453,7 +1453,7 @@ LdrpProcessImportDirectory(
|
||||||
PCHAR Name;
|
PCHAR Name;
|
||||||
ULONG Size;
|
ULONG Size;
|
||||||
|
|
||||||
DPRINT("LdrpProcessImportDirectory(%x '%wZ', '%s')\n",
|
DPRINT("LdrpProcessImportDirectory(%p '%wZ', '%s')\n",
|
||||||
Module, &Module->BaseDllName, ImportedName);
|
Module, &Module->BaseDllName, ImportedName);
|
||||||
|
|
||||||
|
|
||||||
|
@ -1507,7 +1507,7 @@ LdrpAdjustImportDirectory(PLDR_DATA_TABLE_ENTRY Module,
|
||||||
PCHAR Name;
|
PCHAR Name;
|
||||||
ULONG Size;
|
ULONG Size;
|
||||||
|
|
||||||
DPRINT("LdrpAdjustImportDirectory(Module %x '%wZ', %x '%wZ', %x '%s')\n",
|
DPRINT("LdrpAdjustImportDirectory(Module %p '%wZ', %p '%wZ', '%s')\n",
|
||||||
Module, &Module->BaseDllName, ImportedModule, &ImportedModule->BaseDllName, ImportedName);
|
Module, &Module->BaseDllName, ImportedModule, &ImportedModule->BaseDllName, ImportedName);
|
||||||
|
|
||||||
ImportModuleDirectory = (PIMAGE_IMPORT_DESCRIPTOR)
|
ImportModuleDirectory = (PIMAGE_IMPORT_DESCRIPTOR)
|
||||||
|
@ -1626,7 +1626,7 @@ LdrFixupImports(IN PWSTR SearchPath OPTIONAL,
|
||||||
PCHAR ImportedName;
|
PCHAR ImportedName;
|
||||||
ULONG Size;
|
ULONG Size;
|
||||||
|
|
||||||
DPRINT("LdrFixupImports(SearchPath %x, Module %x)\n", SearchPath, Module);
|
DPRINT("LdrFixupImports(SearchPath %S, Module %p)\n", SearchPath, Module);
|
||||||
|
|
||||||
/* Check for tls data */
|
/* Check for tls data */
|
||||||
TlsDirectory = (PIMAGE_TLS_DIRECTORY)
|
TlsDirectory = (PIMAGE_TLS_DIRECTORY)
|
||||||
|
@ -1669,7 +1669,7 @@ LdrFixupImports(IN PWSTR SearchPath OPTIONAL,
|
||||||
}
|
}
|
||||||
if (BoundImportDescriptor)
|
if (BoundImportDescriptor)
|
||||||
{
|
{
|
||||||
DPRINT("BoundImportDescriptor %x\n", BoundImportDescriptor);
|
DPRINT("BoundImportDescriptor %p\n", BoundImportDescriptor);
|
||||||
|
|
||||||
BoundImportDescriptorCurrent = BoundImportDescriptor;
|
BoundImportDescriptorCurrent = BoundImportDescriptor;
|
||||||
while (BoundImportDescriptorCurrent->OffsetModuleName)
|
while (BoundImportDescriptorCurrent->OffsetModuleName)
|
||||||
|
@ -1794,7 +1794,7 @@ LdrFixupImports(IN PWSTR SearchPath OPTIONAL,
|
||||||
}
|
}
|
||||||
else if (ImportModuleDirectory)
|
else if (ImportModuleDirectory)
|
||||||
{
|
{
|
||||||
DPRINT("ImportModuleDirectory %x\n", ImportModuleDirectory);
|
DPRINT("ImportModuleDirectory %p\n", ImportModuleDirectory);
|
||||||
|
|
||||||
ImportModuleDirectoryCurrent = ImportModuleDirectory;
|
ImportModuleDirectoryCurrent = ImportModuleDirectory;
|
||||||
while (ImportModuleDirectoryCurrent->Name)
|
while (ImportModuleDirectoryCurrent->Name)
|
||||||
|
@ -1873,8 +1873,8 @@ PEPFUNC LdrPEStartup (PVOID ImageBase,
|
||||||
PIMAGE_NT_HEADERS NTHeaders;
|
PIMAGE_NT_HEADERS NTHeaders;
|
||||||
PLDR_DATA_TABLE_ENTRY tmpModule;
|
PLDR_DATA_TABLE_ENTRY tmpModule;
|
||||||
|
|
||||||
DPRINT("LdrPEStartup(ImageBase %x SectionHandle %x)\n",
|
DPRINT("LdrPEStartup(ImageBase %p SectionHandle %p)\n",
|
||||||
ImageBase, (ULONG)SectionHandle);
|
ImageBase, SectionHandle);
|
||||||
|
|
||||||
/*
|
/*
|
||||||
* Overlay DOS and WNT headers structures
|
* Overlay DOS and WNT headers structures
|
||||||
|
@ -1952,14 +1952,14 @@ PEPFUNC LdrPEStartup (PVOID ImageBase,
|
||||||
/*
|
/*
|
||||||
* Compute the DLL's entry point's address.
|
* Compute the DLL's entry point's address.
|
||||||
*/
|
*/
|
||||||
DPRINT("ImageBase = %x\n",(ULONG)ImageBase);
|
DPRINT("ImageBase = %p\n", ImageBase);
|
||||||
DPRINT("AddressOfEntryPoint = %x\n",(ULONG)NTHeaders->OptionalHeader.AddressOfEntryPoint);
|
DPRINT("AddressOfEntryPoint = 0x%lx\n",(ULONG)NTHeaders->OptionalHeader.AddressOfEntryPoint);
|
||||||
if (NTHeaders->OptionalHeader.AddressOfEntryPoint != 0)
|
if (NTHeaders->OptionalHeader.AddressOfEntryPoint != 0)
|
||||||
{
|
{
|
||||||
EntryPoint = (PEPFUNC) ((ULONG_PTR)ImageBase
|
EntryPoint = (PEPFUNC) ((ULONG_PTR)ImageBase
|
||||||
+ NTHeaders->OptionalHeader.AddressOfEntryPoint);
|
+ NTHeaders->OptionalHeader.AddressOfEntryPoint);
|
||||||
}
|
}
|
||||||
DPRINT("LdrPEStartup() = %x\n",EntryPoint);
|
DPRINT("LdrPEStartup() = %p\n",EntryPoint);
|
||||||
return EntryPoint;
|
return EntryPoint;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -2032,7 +2032,7 @@ LdrpLoadModule(IN PWSTR SearchPath OPTIONAL,
|
||||||
PAGE_READONLY);
|
PAGE_READONLY);
|
||||||
if (!NT_SUCCESS(Status))
|
if (!NT_SUCCESS(Status))
|
||||||
{
|
{
|
||||||
DPRINT1("map view of section failed (Status %x)\n", Status);
|
DPRINT1("map view of section failed (Status 0x%08lx)\n", Status);
|
||||||
RtlFreeUnicodeString(&FullDosName);
|
RtlFreeUnicodeString(&FullDosName);
|
||||||
NtClose(SectionHandle);
|
NtClose(SectionHandle);
|
||||||
return(Status);
|
return(Status);
|
||||||
|
@ -2069,7 +2069,7 @@ LdrpLoadModule(IN PWSTR SearchPath OPTIONAL,
|
||||||
* relocation. */
|
* relocation. */
|
||||||
if (ImageBase != (PVOID) NtHeaders->OptionalHeader.ImageBase)
|
if (ImageBase != (PVOID) NtHeaders->OptionalHeader.ImageBase)
|
||||||
{
|
{
|
||||||
DPRINT1("Relocating (%x -> %x) %wZ\n",
|
DPRINT1("Relocating (%lx -> %p) %wZ\n",
|
||||||
NtHeaders->OptionalHeader.ImageBase, ImageBase, &FullDosName);
|
NtHeaders->OptionalHeader.ImageBase, ImageBase, &FullDosName);
|
||||||
Status = LdrPerformRelocations(NtHeaders, ImageBase);
|
Status = LdrPerformRelocations(NtHeaders, ImageBase);
|
||||||
if (!NT_SUCCESS(Status))
|
if (!NT_SUCCESS(Status))
|
||||||
|
@ -2254,7 +2254,7 @@ LdrDisableThreadCalloutsForDll(IN PVOID BaseAddress)
|
||||||
PLDR_DATA_TABLE_ENTRY Module;
|
PLDR_DATA_TABLE_ENTRY Module;
|
||||||
NTSTATUS Status;
|
NTSTATUS Status;
|
||||||
|
|
||||||
DPRINT("LdrDisableThreadCalloutsForDll (BaseAddress %x)\n", BaseAddress);
|
DPRINT("LdrDisableThreadCalloutsForDll (BaseAddress %p)\n", BaseAddress);
|
||||||
|
|
||||||
Status = STATUS_DLL_NOT_FOUND;
|
Status = STATUS_DLL_NOT_FOUND;
|
||||||
RtlEnterCriticalSection (NtCurrentPeb()->LoaderLock);
|
RtlEnterCriticalSection (NtCurrentPeb()->LoaderLock);
|
||||||
|
@ -2264,7 +2264,7 @@ LdrDisableThreadCalloutsForDll(IN PVOID BaseAddress)
|
||||||
{
|
{
|
||||||
Module = CONTAINING_RECORD(Entry, LDR_DATA_TABLE_ENTRY, InLoadOrderModuleList);
|
Module = CONTAINING_RECORD(Entry, LDR_DATA_TABLE_ENTRY, InLoadOrderModuleList);
|
||||||
|
|
||||||
DPRINT("BaseDllName %wZ BaseAddress %x\n", &Module->BaseDllName, Module->DllBase);
|
DPRINT("BaseDllName %wZ BaseAddress %p\n", &Module->BaseDllName, Module->DllBase);
|
||||||
|
|
||||||
if (Module->DllBase == BaseAddress)
|
if (Module->DllBase == BaseAddress)
|
||||||
{
|
{
|
||||||
|
@ -2300,7 +2300,7 @@ LdrGetDllHandle(IN PWSTR DllPath OPTIONAL,
|
||||||
if (DllName == NULL)
|
if (DllName == NULL)
|
||||||
{
|
{
|
||||||
*DllHandle = ExeModule->DllBase;
|
*DllHandle = ExeModule->DllBase;
|
||||||
DPRINT("BaseAddress %x\n", *DllHandle);
|
DPRINT("BaseAddress 0x%lx\n", *DllHandle);
|
||||||
return STATUS_SUCCESS;
|
return STATUS_SUCCESS;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -2335,7 +2335,7 @@ LdrGetProcedureAddress (IN PVOID BaseAddress,
|
||||||
TRACE_LDR("LdrGetProcedureAddress by ORDINAL - %d\n", Ordinal);
|
TRACE_LDR("LdrGetProcedureAddress by ORDINAL - %d\n", Ordinal);
|
||||||
}
|
}
|
||||||
|
|
||||||
DPRINT("LdrGetProcedureAddress (BaseAddress %x Name %Z Ordinal %lu ProcedureAddress %x)\n",
|
DPRINT("LdrGetProcedureAddress (BaseAddress %p Name %Z Ordinal %lu ProcedureAddress %p)\n",
|
||||||
BaseAddress, Name, Ordinal, ProcedureAddress);
|
BaseAddress, Name, Ordinal, ProcedureAddress);
|
||||||
|
|
||||||
if (Name && Name->Length)
|
if (Name && Name->Length)
|
||||||
|
@ -2357,7 +2357,7 @@ LdrGetProcedureAddress (IN PVOID BaseAddress,
|
||||||
{
|
{
|
||||||
return STATUS_SUCCESS;
|
return STATUS_SUCCESS;
|
||||||
}
|
}
|
||||||
DPRINT("LdrGetProcedureAddress: Can't resolve symbol @%d\n", Ordinal);
|
DPRINT("LdrGetProcedureAddress: Can't resolve symbol @%lu\n", Ordinal);
|
||||||
}
|
}
|
||||||
return STATUS_PROCEDURE_NOT_FOUND;
|
return STATUS_PROCEDURE_NOT_FOUND;
|
||||||
}
|
}
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue