mirror of
https://github.com/reactos/reactos.git
synced 2025-01-03 21:09:19 +00:00
[NTDLL]
* Fix Cookie for loader locking generation Silences "LdrUnlockLoaderLock() called with an invalid cookie!" debug messages svn path=/trunk/; revision=56874
This commit is contained in:
parent
dc476b6bf5
commit
f9a6dfab7d
1 changed files with 7 additions and 7 deletions
|
@ -37,7 +37,7 @@ LdrpMakeCookie(VOID)
|
||||||
{
|
{
|
||||||
/* Generate a cookie */
|
/* Generate a cookie */
|
||||||
return (((ULONG_PTR)NtCurrentTeb()->RealClientId.UniqueThread & 0xFFF) << 16) |
|
return (((ULONG_PTR)NtCurrentTeb()->RealClientId.UniqueThread & 0xFFF) << 16) |
|
||||||
_InterlockedIncrement(&LdrpLoaderLockAcquisitonCount);
|
(_InterlockedIncrement(&LdrpLoaderLockAcquisitonCount) & 0xFFFF);
|
||||||
}
|
}
|
||||||
|
|
||||||
/*
|
/*
|
||||||
|
@ -1540,19 +1540,19 @@ NTAPI
|
||||||
LdrUnloadAlternateResourceModule(IN PVOID BaseAddress)
|
LdrUnloadAlternateResourceModule(IN PVOID BaseAddress)
|
||||||
{
|
{
|
||||||
ULONG_PTR Cookie;
|
ULONG_PTR Cookie;
|
||||||
|
|
||||||
/* Acquire the loader lock */
|
/* Acquire the loader lock */
|
||||||
LdrLockLoaderLock(TRUE, NULL, &Cookie);
|
LdrLockLoaderLock(TRUE, NULL, &Cookie);
|
||||||
|
|
||||||
/* Check if there's any alternate resources loaded */
|
/* Check if there's any alternate resources loaded */
|
||||||
if (AlternateResourceModuleCount)
|
if (AlternateResourceModuleCount)
|
||||||
{
|
{
|
||||||
UNIMPLEMENTED;
|
UNIMPLEMENTED;
|
||||||
}
|
}
|
||||||
|
|
||||||
/* Release the loader lock */
|
/* Release the loader lock */
|
||||||
LdrUnlockLoaderLock(1, Cookie);
|
LdrUnlockLoaderLock(1, Cookie);
|
||||||
|
|
||||||
/* All done */
|
/* All done */
|
||||||
return TRUE;
|
return TRUE;
|
||||||
}
|
}
|
||||||
|
@ -1570,9 +1570,9 @@ LdrLoadAlternateResourceModule(IN PVOID Module,
|
||||||
{
|
{
|
||||||
/* Is MUI Support enabled? */
|
/* Is MUI Support enabled? */
|
||||||
if (!LdrAlternateResourcesEnabled()) return STATUS_SUCCESS;
|
if (!LdrAlternateResourcesEnabled()) return STATUS_SUCCESS;
|
||||||
|
|
||||||
UNIMPLEMENTED;
|
UNIMPLEMENTED;
|
||||||
return STATUS_MUI_FILE_NOT_FOUND;
|
return STATUS_MUI_FILE_NOT_FOUND;
|
||||||
}
|
}
|
||||||
|
|
||||||
/* EOF */
|
/* EOF */
|
||||||
|
|
Loading…
Reference in a new issue