Author: dgorbachev
Date: Mon Apr 30 12:41:42 2007
New Revision: 26584
URL:
http://svn.reactos.org/svn/reactos?rev=26584&view=rev
Log:
Add RtlDllShutdownInProgress().
Modified:
trunk/reactos/dll/ntdll/def/ntdll.def
trunk/reactos/dll/ntdll/ldr/utils.c
Modified: trunk/reactos/dll/ntdll/def/ntdll.def
URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/dll/ntdll/def/ntdll.def?re…
==============================================================================
--- trunk/reactos/dll/ntdll/def/ntdll.def (original)
+++ trunk/reactos/dll/ntdll/def/ntdll.def Mon Apr 30 12:41:42 2007
@@ -411,6 +411,7 @@
RtlDestroyProcessParameters@4
RtlDestroyQueryDebugBuffer@4
RtlDetermineDosPathNameType_U@4
+RtlDllShutdownInProgress@0
RtlDoesFileExists_U@4
RtlDosPathNameToNtPathName_U@16
RtlDosPathNameToRelativeNtPathName_U@16
Modified: trunk/reactos/dll/ntdll/ldr/utils.c
URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/dll/ntdll/ldr/utils.c?rev=…
==============================================================================
--- trunk/reactos/dll/ntdll/ldr/utils.c (original)
+++ trunk/reactos/dll/ntdll/ldr/utils.c Mon Apr 30 12:41:42 2007
@@ -45,6 +45,7 @@
PLDR_DATA_TABLE_ENTRY Module;
} TLS_DATA, *PTLS_DATA;
+static BOOLEAN LdrpDllShutdownInProgress = FALSE;
static PTLS_DATA LdrpTlsArray = NULL;
static ULONG LdrpTlsCount = 0;
static ULONG LdrpTlsSize = 0;
@@ -2485,6 +2486,9 @@
DPRINT("LdrpDetachProcess() called for %wZ\n",
&ExeModule->BaseDllName);
+ if (UnloadAll)
+ LdrpDllShutdownInProgress = TRUE;
+
CallingCount++;
ModuleListHead = &NtCurrentPeb()->Ldr->InInitializationOrderModuleList;
@@ -2617,6 +2621,15 @@
/*
* @implemented
*/
+BOOLEAN NTAPI
+RtlDllShutdownInProgress (VOID)
+{
+ return LdrpDllShutdownInProgress;
+}
+
+/*
+ * @implemented
+ */
NTSTATUS NTAPI
LdrShutdownProcess (VOID)
{