]> git.proxmox.com Git - mirror_edk2.git/blobdiff - BaseTools/Source/C/Common/StringFuncs.c
BaseTools: Clean up source files
[mirror_edk2.git] / BaseTools / Source / C / Common / StringFuncs.c
index b0ad2d165e10939337e7e3dcb382244c73618adf..65d14140681ca2dcf7347ffe5764823c534649e0 100644 (file)
@@ -1,21 +1,14 @@
 /** @file\r
+Function prototypes and defines for string routines.\r
 \r
-Copyright (c) 2007 - 2008, Intel Corporation                                                         \r
-All rights reserved. This program and the accompanying materials                          \r
-are licensed and made available under the terms and conditions of the BSD License         \r
-which accompanies this distribution.  The full text of the license may be found at        \r
-http://opensource.org/licenses/bsd-license.php                                            \r
-                                                                                          \r
-THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,                     \r
-WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.             \r
+Copyright (c) 2007 - 2018, Intel Corporation. All rights reserved.<BR>\r
+This program and the accompanying materials\r
+are licensed and made available under the terms and conditions of the BSD License\r
+which accompanies this distribution.  The full text of the license may be found at\r
+http://opensource.org/licenses/bsd-license.php\r
 \r
-Module Name:\r
-\r
-  StringFuncs.c\r
-\r
-Abstract:\r
-\r
-  Function prototypes and defines for string routines.\r
+THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,\r
+WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.\r
 \r
 **/\r
 \r
@@ -87,7 +80,7 @@ Returns:
   //\r
   // Remove leading whitespace\r
   //\r
-  for (Pos = String; isspace (*Pos); Pos++) {\r
+  for (Pos = String; isspace ((int)*Pos); Pos++) {\r
   }\r
   if (Pos != String) {\r
     memmove (String, Pos, strlen (Pos) + 1);\r
@@ -114,7 +107,7 @@ Returns:
   // Remove trailing whitespace\r
   //\r
   for (Pos = String + strlen (String);\r
-       ((Pos - 1) >= String) && (isspace (*(Pos - 1)));\r
+       ((Pos - 1) >= String) && (isspace ((int)*(Pos - 1)));\r
        Pos--\r
       ) {\r
   }\r
@@ -160,12 +153,12 @@ Returns:
   Output = NewStringList ();\r
 \r
   for (Pos = String, Item = 0; Pos < EndOfString; Item++) {\r
-    while (isspace (*Pos)) {\r
+    while (isspace ((int)*Pos)) {\r
       Pos++;\r
     }\r
 \r
     for (EndOfSubString=Pos;\r
-         (*EndOfSubString != '\0') && !isspace (*EndOfSubString);\r
+         (*EndOfSubString != '\0') && !isspace ((int)*EndOfSubString);\r
          EndOfSubString++\r
          ) {\r
     }\r
@@ -390,7 +383,7 @@ Returns:
     strcat (NewString, "\"");\r
   }\r
   strcat (NewString, "]");\r
-  \r
+\r
   return NewString;\r
 }\r
 \r