]> git.proxmox.com Git - mirror_edk2.git/blobdiff - ShellPkg/Library/UefiShellLevel2CommandsLib/Map.c
Update Code to pass EBC compiler.
[mirror_edk2.git] / ShellPkg / Library / UefiShellLevel2CommandsLib / Map.c
index 78e432bcd4f98f8fc1b4186ded67675bce613841..2725f4ad39124a8d241e3e2eab69e29bc375d74f 100644 (file)
@@ -1,7 +1,7 @@
 /** @file\r
   Main file for map shell level 2 command.\r
 \r
-  Copyright (c) 2009 - 2011, Intel Corporation. All rights reserved.<BR>\r
+  Copyright (c) 2009 - 2013, 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
@@ -1091,18 +1091,15 @@ ShellCommandRunMap (
           if (SName != NULL) {\r
             Status = PerformMappingDelete(SName);\r
             if (EFI_ERROR(Status)) {\r
-              switch (Status) {\r
-                case EFI_ACCESS_DENIED:\r
-                  ShellPrintHiiEx(-1, -1, NULL, STRING_TOKEN (STR_GEN_ERR_AD), gShellLevel2HiiHandle);\r
-                  ShellStatus = SHELL_ACCESS_DENIED;\r
-                  break;\r
-                case EFI_NOT_FOUND:\r
-                  ShellPrintHiiEx(-1, -1, NULL, STRING_TOKEN (STR_MAP_NF), gShellLevel2HiiHandle, SName);\r
-                  ShellStatus = SHELL_INVALID_PARAMETER;\r
-                  break;\r
-                default:\r
-                  ShellPrintHiiEx(-1, -1, NULL, STRING_TOKEN (STR_GEN_ERR_UK), gShellLevel2HiiHandle, Status);\r
-                  ShellStatus = SHELL_UNSUPPORTED;\r
+              if (Status == EFI_ACCESS_DENIED) {\r
+                ShellPrintHiiEx(-1, -1, NULL, STRING_TOKEN (STR_GEN_ERR_AD), gShellLevel2HiiHandle);\r
+                ShellStatus = SHELL_ACCESS_DENIED;\r
+              } else if (Status == EFI_NOT_FOUND) {\r
+                ShellPrintHiiEx(-1, -1, NULL, STRING_TOKEN (STR_MAP_NF), gShellLevel2HiiHandle, SName);\r
+                ShellStatus = SHELL_INVALID_PARAMETER;\r
+              } else {\r
+                ShellPrintHiiEx(-1, -1, NULL, STRING_TOKEN (STR_GEN_ERR_UK), gShellLevel2HiiHandle, Status);\r
+                ShellStatus = SHELL_UNSUPPORTED;\r
               }\r
             }\r
           } else {\r