Author: fireball
Date: Fri Apr 8 09:21:41 2011
New Revision: 51277
URL:
http://svn.reactos.org/svn/reactos?rev=51277&view=rev
Log:
[KERNEL32]
- Zero-initialize base address in BasepLoadLibraryAsDatafile. Should fix 2nd stage
problems.
- Add a trace debugprint, silented by default.
See issue #6092 for more details.
Modified:
trunk/reactos/dll/win32/kernel32/misc/ldr.c
Modified: trunk/reactos/dll/win32/kernel32/misc/ldr.c
URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/dll/win32/kernel32/misc/ld…
==============================================================================
--- trunk/reactos/dll/win32/kernel32/misc/ldr.c [iso-8859-1] (original)
+++ trunk/reactos/dll/win32/kernel32/misc/ldr.c [iso-8859-1] Fri Apr 8 09:21:41 2011
@@ -274,13 +274,15 @@
HANDLE hFile = INVALID_HANDLE_VALUE;
HANDLE hMapping;
NTSTATUS Status;
- PVOID lpBaseAddress;
+ PVOID lpBaseAddress = NULL;
SIZE_T ViewSize;
//PUNICODE_STRING OriginalName;
//UNICODE_STRING dotDLL = RTL_CONSTANT_STRING(L".DLL");
/* Zero out handle value */
*hModule = 0;
+
+ DPRINT("BasepLoadLibraryAsDatafile(%S %S %p)\n", Path, Name, hModule);
/*Status = RtlDosApplyFileIsolationRedirection_Ustr(TRUE,
Name,
@@ -470,7 +472,7 @@
if (FreeString) RtlFreeUnicodeString(&DllName);
/* Set last error in failure case */
- if ( !NT_SUCCESS(Status))
+ if (!NT_SUCCESS(Status))
{
BaseSetLastNTError(Status);
return NULL;