]> git.proxmox.com Git - mirror_edk2.git/blobdiff - IntelFrameworkModulePkg/Library/GenericBdsLib/DevicePath.c
Update code style and comments
[mirror_edk2.git] / IntelFrameworkModulePkg / Library / GenericBdsLib / DevicePath.c
index bfc668f5b7acb5112dd7b57ba3ea4e49bca4864b..bdb69b4b6fa13afdb37be245c238893ce7be6cae 100644 (file)
@@ -20,7 +20,7 @@ WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
   The caller must free the resulting buffer.\r
 \r
   @param  Str      Tracks the allocated pool, size in use, and amount of pool allocated.\r
-  @param  fmt      The format string\r
+  @param  Fmt      The format string\r
   @param  ...      The data will be printed.\r
 \r
   @return Allocated buffer with the formatted string printed in it.\r
@@ -32,7 +32,7 @@ CHAR16 *
 EFIAPI\r
 CatPrint (\r
   IN OUT POOL_PRINT   *Str,\r
-  IN CHAR16           *fmt,\r
+  IN CHAR16           *Fmt,\r
   ...\r
   )\r
 {\r
@@ -42,36 +42,36 @@ CatPrint (
 \r
   AppendStr = AllocateZeroPool (0x1000);\r
   if (AppendStr == NULL) {\r
-    return Str->str;\r
+    return Str->Str;\r
   }\r
 \r
-  VA_START (Args, fmt);\r
-  UnicodeVSPrint (AppendStr, 0x1000, fmt, Args);\r
+  VA_START (Args, Fmt);\r
+  UnicodeVSPrint (AppendStr, 0x1000, Fmt, Args);\r
   VA_END (Args);\r
-  if (NULL == Str->str) {\r
+  if (NULL == Str->Str) {\r
     StringSize   = StrSize (AppendStr);\r
-    Str->str  = AllocateZeroPool (StringSize);\r
-    ASSERT (Str->str != NULL);\r
+    Str->Str  = AllocateZeroPool (StringSize);\r
+    ASSERT (Str->Str != NULL);\r
   } else {\r
     StringSize = StrSize (AppendStr);\r
-    StringSize += (StrSize (Str->str) - sizeof (UINT16));\r
+    StringSize += (StrSize (Str->Str) - sizeof (UINT16));\r
 \r
-    Str->str = ReallocatePool (\r
-                StrSize (Str->str),\r
+    Str->Str = ReallocatePool (\r
+                StrSize (Str->Str),\r
                 StringSize,\r
-                Str->str\r
+                Str->Str\r
                 );\r
-    ASSERT (Str->str != NULL);\r
+    ASSERT (Str->Str != NULL);\r
   }\r
 \r
-  Str->maxlen = MAX_CHAR * sizeof (UINT16);\r
-  if (StringSize < Str->maxlen) {\r
-    StrCat (Str->str, AppendStr);\r
-    Str->len = StringSize - sizeof (UINT16);\r
+  Str->Maxlen = MAX_CHAR * sizeof (UINT16);\r
+  if (StringSize < Str->Maxlen) {\r
+    StrCat (Str->Str, AppendStr);\r
+    Str->Len = StringSize - sizeof (UINT16);\r
   }\r
 \r
   FreePool (AppendStr);\r
-  return Str->str;\r
+  return Str->Str;\r
 }\r
 \r
 /**\r
@@ -1521,7 +1521,7 @@ DevicePathToStr (
     //\r
     //  Put a path seperator in if needed\r
     //\r
-    if (Str.len && DumpNode != DevPathEndInstance) {\r
+    if (Str.Len && DumpNode != DevPathEndInstance) {\r
       CatPrint (&Str, L"/");\r
     }\r
     //\r
@@ -1536,9 +1536,9 @@ DevicePathToStr (
   }\r
 \r
 Done:\r
-  NewSize = (Str.len + 1) * sizeof (CHAR16);\r
-  Str.str = ReallocatePool (NewSize, NewSize, Str.str);\r
-  ASSERT (Str.str != NULL);\r
-  Str.str[Str.len] = 0;\r
-  return Str.str;\r
+  NewSize = (Str.Len + 1) * sizeof (CHAR16);\r
+  Str.Str = ReallocatePool (NewSize, NewSize, Str.Str);\r
+  ASSERT (Str.Str != NULL);\r
+  Str.Str[Str.Len] = 0;\r
+  return Str.Str;\r
 }\r