[ros-diffs] [tkreuzer] 49614: [NTOSKRNL] - Initialize the Zero variable - Don't corrupt the Color value in case we didn't have any page on MmZeroedPageListHead. - Fixes boot.

tkreuzer at svn.reactos.org tkreuzer at svn.reactos.org
Thu Nov 18 19:20:39 UTC 2010


Author: tkreuzer
Date: Thu Nov 18 19:20:38 2010
New Revision: 49614

URL: http://svn.reactos.org/svn/reactos?rev=49614&view=rev
Log:
[NTOSKRNL]
- Initialize the Zero variable
- Don't corrupt the Color value in case we didn't have any page on MmZeroedPageListHead.
- Fixes boot.

Modified:
    trunk/reactos/ntoskrnl/mm/ARM3/pfnlist.c

Modified: trunk/reactos/ntoskrnl/mm/ARM3/pfnlist.c
URL: http://svn.reactos.org/svn/reactos/trunk/reactos/ntoskrnl/mm/ARM3/pfnlist.c?rev=49614&r1=49613&r2=49614&view=diff
==============================================================================
--- trunk/reactos/ntoskrnl/mm/ARM3/pfnlist.c [iso-8859-1] (original)
+++ trunk/reactos/ntoskrnl/mm/ARM3/pfnlist.c [iso-8859-1] Thu Nov 18 19:20:38 2010
@@ -407,7 +407,7 @@
 {
     PFN_NUMBER PageIndex;
     PMMPFN Pfn1;
-    BOOLEAN Zero;
+    BOOLEAN Zero = FALSE;
 
     /* Make sure PFN lock is held and we have pages */
     ASSERT(KeGetCurrentIrql() == DISPATCH_LEVEL);
@@ -421,7 +421,6 @@
         /* Check the zero list */
         ASSERT_LIST_INVARIANT(&MmZeroedPageListHead);
         PageIndex = MmZeroedPageListHead.Flink;
-        Color = PageIndex & MmSecondaryColorMask;
         if (PageIndex == LIST_HEAD)
         {
             /* This means there's no zero pages, we have to look for free ones */
@@ -444,6 +443,10 @@
                 }
             }
         }
+        else
+        {
+            Color = PageIndex & MmSecondaryColorMask;
+        }
     }
 
     /* Sanity checks */




More information about the Ros-diffs mailing list