Dhcp6 internal functions implementation.\r
\r
(C) Copyright 2014 Hewlett-Packard Development Company, L.P.<BR>\r
- Copyright (c) 2009 - 2015, Intel Corporation. All rights reserved.<BR>\r
+ Copyright (c) 2009 - 2018, Intel Corporation. All rights reserved.<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
- 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
+ SPDX-License-Identifier: BSD-2-Clause-Patent\r
\r
**/\r
\r
\r
@retval TRUE The control block is in Instance's retry list.\r
@retval FALSE The control block is NOT in Instance's retry list.\r
- \r
+\r
**/\r
BOOLEAN\r
Dhcp6IsValidTxCb (\r
if (EFI_ERROR (Status) && (Status != EFI_ALREADY_STARTED)) {\r
goto ON_ERROR;\r
}\r
- \r
+\r
gBS->RestoreTPL (OldTpl);\r
return EFI_SUCCESS;\r
- \r
+\r
ON_ERROR:\r
- gBS->RestoreTPL (OldTpl); \r
+ gBS->RestoreTPL (OldTpl);\r
RemoveEntryList (&InfCb->Link);\r
FreePool (InfCb);\r
\r
//\r
Packet->Length += (UINT32) (Cursor - Packet->Dhcp6.Option);\r
ASSERT (Packet->Size > Packet->Length + 8);\r
- \r
+\r
//\r
// Clear initial time for current transaction.\r
//\r
}\r
} else if (Status == EFI_NOT_FOUND) {\r
//\r
- // Refer to RFC3315 Chapter 18.1.8, for each IA in the original Renew or Rebind message, \r
+ // Refer to RFC3315 Chapter 18.1.8, for each IA in the original Renew or Rebind message,\r
// the client sends a Renew or Rebind if the IA is not in the Reply message.\r
// Return EFI_SUCCESS so we can continue to restart the Renew/Rebind process.\r
//\r
return EFI_SUCCESS;\r
}\r
- \r
+\r
goto ON_EXIT;\r
- \r
+\r
} else if (Option != NULL) {\r
//\r
// Any error status code option is found.\r
case Dhcp6StsNoBinding:\r
if (Instance->IaCb.Ia->State == Dhcp6Renewing || Instance->IaCb.Ia->State == Dhcp6Rebinding) {\r
//\r
- // Refer to RFC3315 Chapter 18.1.8, for each IA in the original Renew or Rebind message, the client \r
+ // Refer to RFC3315 Chapter 18.1.8, for each IA in the original Renew or Rebind message, the client\r
// sends a Request message if the IA contained a Status Code option with the NoBinding status.\r
//\r
Status = Dhcp6SendRequestMsg(Instance);\r
}\r
\r
return EFI_SUCCESS;\r
- \r
+\r
ON_EXIT:\r
\r
if (!EFI_ERROR(Status)) {\r
FALSE\r
);\r
}\r
- \r
+\r
return Status;\r
}\r
\r
return ;\r
}\r
\r
+ if (Udp6Wrap->TotalSize < sizeof (EFI_DHCP6_HEADER)) {\r
+ goto ON_CONTINUE;\r
+ }\r
+\r
//\r
// Copy the net buffer received from upd6 to a Dhcp6 packet.\r
//\r
0\r
);\r
if (EFI_ERROR (Status)) {\r
- Dhcp6CleanupRetry (Instance, DHCP6_PACKET_ALL);\r
+ NET_LIST_FOR_EACH_SAFE (Entry1, Next1, &Service->Child) {\r
+ Instance = NET_LIST_USER_STRUCT (Entry1, DHCP6_INSTANCE, Link);\r
+ Dhcp6CleanupRetry (Instance, DHCP6_PACKET_ALL);\r
+ }\r
}\r
}\r
\r