/** @file\r
The implementation of EFI IPv6 Configuration Protocol.\r
\r
- Copyright (c) 2009 - 2016, Intel Corporation. All rights reserved.<BR>\r
+ Copyright (c) 2009 - 2017, 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
//\r
// The dns server address must be unicast.\r
//\r
- FreePool (Tmp);\r
+ if (Tmp != NULL) {\r
+ FreePool (Tmp);\r
+ }\r
return EFI_INVALID_PARAMETER;\r
}\r
\r
for (Index1 = NewIndex + 1; Index1 < NewDnsCount; Index1++) {\r
if (EFI_IP6_EQUAL (NewDns + NewIndex, NewDns + Index1)) {\r
- FreePool (Tmp);\r
+ if (Tmp != NULL) {\r
+ FreePool (Tmp);\r
+ }\r
return EFI_INVALID_PARAMETER;\r
}\r
}\r