Functions implementation related with DHCPv6 for UefiPxeBc Driver.\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 - 2016, 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
return Status;\r
}\r
\r
- ASSERT (Mode.Ia->State == Dhcp6Bound);\r
+ ASSERT ((Mode.Ia != NULL) && (Mode.Ia->State == Dhcp6Bound));\r
//\r
// DHCP6 doesn't have an option to specify the router address on the subnet, the only way to get the\r
// router address in IP6 is the router discovery mechanism (the RS and RA, which only be handled when\r
// to find a valid router address.\r
//\r
CopyMem (&Private->TmpStationIp.v6, &Mode.Ia->IaAddress[0].IpAddress, sizeof (EFI_IPv6_ADDRESS));\r
-\r
+ if (Mode.ClientId != NULL) {\r
+ FreePool (Mode.ClientId);\r
+ }\r
+ if (Mode.Ia != NULL) {\r
+ FreePool (Mode.Ia);\r
+ }\r
//\r
// Check the selected offer whether BINL retry is needed.\r
//\r