]> git.proxmox.com Git - mirror_edk2.git/blobdiff - MdeModulePkg/Core/Dxe/FwVol/FwVolRead.c
Code scrub for DxeCore
[mirror_edk2.git] / MdeModulePkg / Core / Dxe / FwVol / FwVolRead.c
index 81e3ad349e9dd038246848a08745adfec565e5fd..7016ee5b9095419a7ab8f2a6a09b103a25af6604 100644 (file)
@@ -200,7 +200,7 @@ FvGetNextFile (
   // Return FileType, NameGuid, and Attributes\r
   //\r
   *FileType = FfsFileHeader->Type;\r
-  CopyMem (NameGuid, &FfsFileHeader->Name, sizeof (EFI_GUID));\r
+  CopyGuid (NameGuid, &FfsFileHeader->Name);\r
   *Attributes = FfsAttributes2FvFileAttributes (FfsFileHeader->Attributes);\r
 \r
   //\r
@@ -280,7 +280,7 @@ FvReadFile (
   EFI_FFS_FILE_HEADER               *FfsHeader;\r
   UINTN                             InputBufferSize;\r
   \r
-  if (NULL == NameGuid) {\r
+  if (NameGuid == NULL) {\r
     return EFI_INVALID_PARAMETER;\r
   }\r
 \r
@@ -412,7 +412,7 @@ FvReadFileSection (
   UINT8                             *FileBuffer;\r
   FFS_FILE_LIST_ENTRY               *FfsEntry;\r
  \r
-  if (NULL == NameGuid || Buffer == NULL) {\r
+  if (NameGuid == NULL || Buffer == NULL) {\r
     return EFI_INVALID_PARAMETER;\r
   }\r
 \r
@@ -434,7 +434,7 @@ FvReadFileSection (
   //\r
   // Get the last key used by our call to FvReadFile as it is the FfsEntry for this file.\r
   //  \r
-  FfsEntry = (FFS_FILE_LIST_ENTRY *)FvDevice->LastKey;\r
+  FfsEntry = (FFS_FILE_LIST_ENTRY *) FvDevice->LastKey;\r
 \r
   if (EFI_ERROR (Status)) {\r
     return Status;\r
@@ -453,10 +453,10 @@ FvReadFileSection (
   //\r
   if (FfsEntry->StreamHandle == 0) {\r
     Status = OpenSectionStream (\r
-                    FileSize,\r
-                    FileBuffer,\r
-                    &FfsEntry->StreamHandle\r
-                    );\r
+               FileSize,\r
+               FileBuffer,\r
+               &FfsEntry->StreamHandle\r
+               );\r
     if (EFI_ERROR (Status)) {\r
       goto Done;\r
     }\r