{
/* Generate a cookie */
return (((ULONG_PTR)NtCurrentTeb()->RealClientId.UniqueThread & 0xFFF) << 16) |
- _InterlockedIncrement(&LdrpLoaderLockAcquisitonCount);
+ (_InterlockedIncrement(&LdrpLoaderLockAcquisitonCount) & 0xFFFF);
}
/*
{
FILE_STANDARD_INFORMATION FileStandardInfo;
PIMAGE_IMPORT_DESCRIPTOR ImportData;
- PIMAGE_SECTION_HEADER LastSection;
+ PIMAGE_SECTION_HEADER LastSection = NULL;
IO_STATUS_BLOCK IoStatusBlock;
PIMAGE_NT_HEADERS NtHeader;
HANDLE SectionHandle;
LdrUnloadAlternateResourceModule(IN PVOID BaseAddress)
{
ULONG_PTR Cookie;
-
+
/* Acquire the loader lock */
LdrLockLoaderLock(TRUE, NULL, &Cookie);
-
+
/* Check if there's any alternate resources loaded */
if (AlternateResourceModuleCount)
{
UNIMPLEMENTED;
}
-
+
/* Release the loader lock */
LdrUnlockLoaderLock(1, Cookie);
-
+
/* All done */
return TRUE;
}
{
/* Is MUI Support enabled? */
if (!LdrAlternateResourcesEnabled()) return STATUS_SUCCESS;
-
+
UNIMPLEMENTED;
return STATUS_MUI_FILE_NOT_FOUND;
}
-
+
/* EOF */