]> git.proxmox.com Git - mirror_edk2.git/blobdiff - NetworkPkg/Ip6Dxe/Ip6Input.c
MdePkg/SmmIoLib: Add header file.
[mirror_edk2.git] / NetworkPkg / Ip6Dxe / Ip6Input.c
index 3f0dce734393f929aabcb564c3c3e87127c98b27..e53e0874b9b52fa9affbb3eb95fbdf913e6f73b3 100644 (file)
@@ -1,7 +1,8 @@
 /** @file\r
   IP6 internal functions to process the incoming packets.\r
 \r
-  Copyright (c) 2009 - 2011, Intel Corporation. All rights reserved.<BR>\r
+  Copyright (c) 2009 - 2014, Intel Corporation. All rights reserved.<BR>\r
+  (C) Copyright 2015 Hewlett-Packard Development Company, L.P.<BR>\r
 \r
   This program and the accompanying materials\r
   are licensed and made available under the terms and conditions of the BSD License\r
@@ -243,7 +244,7 @@ Ip6Reassemble (
   // check whether THIS.Start < PREV.End for overlap. If two fragments\r
   // overlaps, trim the overlapped part off THIS fragment.\r
   //\r
-  if ((Cur != ListHead) && ((Prev = Cur->BackLink) != ListHead)) {\r
+  if ((Prev = Cur->BackLink) != ListHead) {\r
     Fragment  = NET_LIST_USER_STRUCT (Prev, NET_BUF, List);\r
     Node      = IP6_GET_CLIP_INFO (Fragment);\r
 \r
@@ -525,6 +526,11 @@ Ip6IpSecProcessPacket (
   EFI_IP6_HEADER            ZeroHead;\r
 \r
   Status        = EFI_SUCCESS;\r
+\r
+  if (!mIpSec2Installed) {\r
+    goto ON_EXIT;\r
+  }\r
+  \r
   Packet        = *Netbuf;\r
   RecycleEvent  = NULL;\r
   IpSecWrap     = NULL;\r