[FREELDR] Minor code style - use RtlZeroMemory(); shorter member name; use different... 1906/head
authorHermès Bélusca-Maïto <hermes.belusca-maito@reactos.org>
Fri, 13 Sep 2019 12:35:16 +0000 (14:35 +0200)
committerHermès Bélusca-Maïto <hermes.belusca-maito@reactos.org>
Fri, 13 Sep 2019 13:18:28 +0000 (15:18 +0200)
boot/freeldr/freeldr/bootmgr.c
boot/freeldr/freeldr/cmdline.c
boot/freeldr/freeldr/ntldr/winldr.c

index bfb8d43..ca2e531 100644 (file)
@@ -22,7 +22,7 @@
 #include <freeldr.h>
 
 #include <debug.h>
-DBG_DEFAULT_CHANNEL(INIFILE);
+DBG_DEFAULT_CHANNEL(WARNING);
 
 /* GLOBALS ********************************************************************/
 
index 19fba95..b7ac90d 100644 (file)
@@ -15,7 +15,7 @@
 typedef struct tagCMDLINEINFO
 {
     PCSTR DebugString;
-    PCSTR DefaultOperatingSystem;
+    PCSTR DefaultOs;
     LONG  TimeOut;
 } CMDLINEINFO, *PCMDLINEINFO;
 
@@ -33,7 +33,7 @@ CmdLineParse(IN PCSTR CmdLine)
 
     /* Set defaults */
     CmdLineInfo.DebugString = NULL;
-    CmdLineInfo.DefaultOperatingSystem = NULL;
+    CmdLineInfo.DefaultOs = NULL;
     CmdLineInfo.TimeOut = -1;
 
     /*
@@ -84,7 +84,7 @@ CmdLineParse(IN PCSTR CmdLine)
 
         /* Copy the default OS */
         RtlStringCbCopyNA(DefaultOs, sizeof(DefaultOs), Setting, Length);
-        CmdLineInfo.DefaultOperatingSystem = DefaultOs;
+        CmdLineInfo.DefaultOs = DefaultOs;
     }
 
     /* Get ramdisk base address */
@@ -128,7 +128,7 @@ CmdLineGetDebugString(VOID)
 PCSTR
 CmdLineGetDefaultOS(VOID)
 {
-    return CmdLineInfo.DefaultOperatingSystem;
+    return CmdLineInfo.DefaultOs;
 }
 
 LONG
index a30d763..fd31040 100644 (file)
@@ -914,8 +914,8 @@ LoadAndBootWindowsCommon(
     TRACE("Hello from paged mode, KiSystemStartup %p, LoaderBlockVA %p!\n",
           KiSystemStartup, LoaderBlockVA);
 
-    // Zero KI_USER_SHARED_DATA page
-    memset((PVOID)KI_USER_SHARED_DATA, 0, MM_PAGE_SIZE);
+    /* Zero KI_USER_SHARED_DATA page */
+    RtlZeroMemory((PVOID)KI_USER_SHARED_DATA, MM_PAGE_SIZE);
 
     WinLdrpDumpMemoryDescriptors(LoaderBlockVA);
     WinLdrpDumpBootDriver(LoaderBlockVA);