From cf6df80709d60116c00a6a8a359cd3de4b7e0dc4 Mon Sep 17 00:00:00 2001
From: Olivier Martin <olivier.martin@arm.com>
Date: Mon, 10 Sep 2012 18:04:46 +0100
Subject: [PATCH] MdeModulePkg: Fixed compiler warning 'unreachable code'

---
 MdeModulePkg/Core/Pei/Dependency/Dependency.c      |    1 -
 MdeModulePkg/Library/UefiHiiLib/HiiLib.c           |    1 -
 MdeModulePkg/Universal/HiiDatabaseDxe/Image.c      |    6 ------
 .../Universal/Network/Tcp4Dxe/Tcp4Dispatcher.c     |    6 ------
 MdeModulePkg/Universal/Network/Tcp4Dxe/Tcp4Input.c |    1 -
 5 files changed, 0 insertions(+), 15 deletions(-)

diff --git a/MdeModulePkg/Core/Pei/Dependency/Dependency.c b/MdeModulePkg/Core/Pei/Dependency/Dependency.c
index eea0feb..d209b8d 100644
--- a/MdeModulePkg/Core/Pei/Dependency/Dependency.c
+++ b/MdeModulePkg/Core/Pei/Dependency/Dependency.c
@@ -196,7 +196,6 @@ PeimDispatchReadiness (
         }
         DEBUG ((DEBUG_DISPATCH, "  RESULT = %a\n", IsPpiInstalled (PeiServices, StackPtr) ? "TRUE" : "FALSE"));
         return IsPpiInstalled (PeiServices, StackPtr);
-        break;
 
       case (EFI_DEP_NOT):    
         DEBUG ((DEBUG_DISPATCH, "  NOT\n"));
diff --git a/MdeModulePkg/Library/UefiHiiLib/HiiLib.c b/MdeModulePkg/Library/UefiHiiLib/HiiLib.c
index 7a2415e..63c85de 100644
--- a/MdeModulePkg/Library/UefiHiiLib/HiiLib.c
+++ b/MdeModulePkg/Library/UefiHiiLib/HiiLib.c
@@ -794,7 +794,6 @@ InternalHiiGetBufferFromString (
 
   default:
     return EFI_INVALID_PARAMETER;
-    break;
   }
 
   return EFI_SUCCESS;
diff --git a/MdeModulePkg/Universal/HiiDatabaseDxe/Image.c b/MdeModulePkg/Universal/HiiDatabaseDxe/Image.c
index db008a0..ccd1975 100644
--- a/MdeModulePkg/Universal/HiiDatabaseDxe/Image.c
+++ b/MdeModulePkg/Universal/HiiDatabaseDxe/Image.c
@@ -882,7 +882,6 @@ HiiGetImage (
     // BUGBUG: need to be supported as soon as image tool is designed.
     //
     return EFI_UNSUPPORTED;
-    break;
 
   case EFI_HII_IIBT_IMAGE_1BIT_TRANS:
   case EFI_HII_IIBT_IMAGE_4BIT_TRANS:
@@ -942,7 +941,6 @@ HiiGetImage (
     }
 
     return EFI_SUCCESS;
-    break;
 
   case EFI_HII_IIBT_IMAGE_24BIT_TRANS:
     Flag = TRUE;
@@ -976,11 +974,9 @@ HiiGetImage (
       (EFI_HII_RGB_PIXEL *) (ImageBlock + sizeof (EFI_HII_IIBT_IMAGE_24BIT_BLOCK) - sizeof (EFI_HII_RGB_PIXEL))
       );
     return EFI_SUCCESS;
-    break;
 
   default:
     return EFI_NOT_FOUND;
-    break;
   }
 }
 
@@ -1087,7 +1083,6 @@ HiiSetImage (
     // BUGBUG: need to be supported as soon as image tool is designed.
     //
     return EFI_UNSUPPORTED;
-    break;
 
   case EFI_HII_IIBT_IMAGE_1BIT:
   case EFI_HII_IIBT_IMAGE_1BIT_TRANS:
@@ -1120,7 +1115,6 @@ HiiSetImage (
     break;
   default:
     return EFI_NOT_FOUND;
-    break;
   }
 
   //
diff --git a/MdeModulePkg/Universal/Network/Tcp4Dxe/Tcp4Dispatcher.c b/MdeModulePkg/Universal/Network/Tcp4Dxe/Tcp4Dispatcher.c
index f86e5c2..688f9a7 100644
--- a/MdeModulePkg/Universal/Network/Tcp4Dxe/Tcp4Dispatcher.c
+++ b/MdeModulePkg/Universal/Network/Tcp4Dxe/Tcp4Dispatcher.c
@@ -662,8 +662,6 @@ Tcp4Dispatcher (
 
     return Tcp4AttachPcb (Sock);
 
-    break;
-
   case SOCK_FLUSH:
 
     Tcp4FlushPcb (Tcb);
@@ -683,16 +681,12 @@ Tcp4Dispatcher (
             (EFI_TCP4_CONFIG_DATA *) Data
             );
 
-    break;
-
   case SOCK_MODE:
 
     ASSERT ((Data != NULL) && (Tcb != NULL));
 
     return Tcp4GetMode (Tcb, (TCP4_MODE_DATA *) Data);
 
-    break;
-
   case SOCK_ROUTE:
 
     ASSERT ((Data != NULL) && (Tcb != NULL));
diff --git a/MdeModulePkg/Universal/Network/Tcp4Dxe/Tcp4Input.c b/MdeModulePkg/Universal/Network/Tcp4Dxe/Tcp4Input.c
index f8dcc36..806ae29 100644
--- a/MdeModulePkg/Universal/Network/Tcp4Dxe/Tcp4Input.c
+++ b/MdeModulePkg/Universal/Network/Tcp4Dxe/Tcp4Input.c
@@ -478,7 +478,6 @@ TcpDeliverData (
         //
         NetbufFree (Nbuf);
         return -1;
-        break;
       default:
         break;
       }
-- 
1.7.0.4

