]> git.proxmox.com Git - mirror_edk2.git/blobdiff - MdeModulePkg/Universal/Network/Tcp4Dxe/Tcp4Dispatcher.c
MdeModulePkg:removes the unreachable ‘break’ instruction after a ‘return’ instruction...
[mirror_edk2.git] / MdeModulePkg / Universal / Network / Tcp4Dxe / Tcp4Dispatcher.c
index 536a16a16cd02afaf637e09518c324f26a872e74..688f9a7e99c9a01e97acef292e4456a275c8dcbf 100644 (file)
@@ -1,7 +1,7 @@
 /** @file\r
   Tcp request dispatcher implementation.\r
 \r
-Copyright (c) 2005 - 2010, Intel Corporation. All rights reserved.<BR>\r
+Copyright (c) 2005 - 2011, 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
@@ -243,6 +243,7 @@ Tcp4FlushPcb (
 \r
   NetbufFreeList (&Tcb->SndQue);\r
   NetbufFreeList (&Tcb->RcvQue);\r
+  Tcb->State = TCP_CLOSED;\r
 }\r
 \r
 /**\r
@@ -661,8 +662,6 @@ Tcp4Dispatcher (
 \r
     return Tcp4AttachPcb (Sock);\r
 \r
-    break;\r
-\r
   case SOCK_FLUSH:\r
 \r
     Tcp4FlushPcb (Tcb);\r
@@ -682,16 +681,12 @@ Tcp4Dispatcher (
             (EFI_TCP4_CONFIG_DATA *) Data\r
             );\r
 \r
-    break;\r
-\r
   case SOCK_MODE:\r
 \r
     ASSERT ((Data != NULL) && (Tcb != NULL));\r
 \r
     return Tcp4GetMode (Tcb, (TCP4_MODE_DATA *) Data);\r
 \r
-    break;\r
-\r
   case SOCK_ROUTE:\r
 \r
     ASSERT ((Data != NULL) && (Tcb != NULL));\r