[ros-diffs] [sir_richard] 46069: [NTOS]: List still-running processes at kernel shutdown. Useful for debugging shutdown code later.

sir_richard at svn.reactos.org sir_richard at svn.reactos.org
Wed Mar 10 19:29:10 CET 2010


Author: sir_richard
Date: Wed Mar 10 19:29:10 2010
New Revision: 46069

URL: http://svn.reactos.org/svn/reactos?rev=46069&view=rev
Log:
[NTOS]: List still-running processes at kernel shutdown. Useful for debugging shutdown code later.

Modified:
    trunk/reactos/ntoskrnl/po/poshtdwn.c

Modified: trunk/reactos/ntoskrnl/po/poshtdwn.c
URL: http://svn.reactos.org/svn/reactos/trunk/reactos/ntoskrnl/po/poshtdwn.c?rev=46069&r1=46068&r2=46069&view=diff
==============================================================================
--- trunk/reactos/ntoskrnl/po/poshtdwn.c [iso-8859-1] (original)
+++ trunk/reactos/ntoskrnl/po/poshtdwn.c [iso-8859-1] Wed Mar 10 19:29:10 2010
@@ -118,6 +118,23 @@
 NTAPI
 PopGracefulShutdown(IN PVOID Context)
 {
+    PEPROCESS Process = NULL;
+
+    /* Loop every process */
+    Process = PsGetNextProcess(Process);
+    while (Process)
+    {
+        /* Make sure this isn't the idle or initial process */
+        if ((Process != PsInitialSystemProcess) && (Process != PsIdleProcess))
+        {
+            /* Print it */
+            DPRINT1("%15s is still RUNNING (%lx)\n", Process->ImageFileName, Process->UniqueProcessId);
+        }
+
+        /* Get the next process */
+        Process = PsGetNextProcess(Process);
+    }
+    
     /* First, the HAL handles any "end of boot" special functionality */
     DPRINT1("HAL shutting down\n");
     HalEndOfBoot();




More information about the Ros-diffs mailing list