summaryrefslogtreecommitdiff
path: root/NetworkPkg/Dhcp6Dxe/Dhcp6Utility.c
diff options
context:
space:
mode:
authorJiaxin Wu <jiaxin.wu@intel.com>2017-02-24 11:16:37 +0800
committerJiaxin Wu <jiaxin.wu@intel.com>2017-03-06 08:32:04 +0800
commit03f9cc20b851ce60f5a629381c288f502eb9432c (patch)
treef666f217ffe987daafb3f91402e24c33966339a9 /NetworkPkg/Dhcp6Dxe/Dhcp6Utility.c
parent3858b4a1ff09d3243fea8d07bd135478237cb8f7 (diff)
downloadedk2-03f9cc20b851ce60f5a629381c288f502eb9432c.zip
edk2-03f9cc20b851ce60f5a629381c288f502eb9432c.tar.gz
edk2-03f9cc20b851ce60f5a629381c288f502eb9432c.tar.bz2
NetworkPkg/Dhcp6Dxe: Handle the Nil UUID case
Nil UUID is a special case with all zeros value. This patch is to handle this case to avoid the invalid DUID. Cc: Naveen Santhapur <naveens@amiindia.co.in> Cc: Ye Ting <ting.ye@intel.com> Cc: Fu Siyuan <siyuan.fu@intel.com> Contributed-under: TianoCore Contribution Agreement 1.0 Signed-off-by: Wu Jiaxin <jiaxin.wu@intel.com> Reviewed-by: Ye Ting <ting.ye@intel.com> Reviewed-by: Fu Siyuan <siyuan.fu@intel.com>
Diffstat (limited to 'NetworkPkg/Dhcp6Dxe/Dhcp6Utility.c')
-rw-r--r--NetworkPkg/Dhcp6Dxe/Dhcp6Utility.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/NetworkPkg/Dhcp6Dxe/Dhcp6Utility.c b/NetworkPkg/Dhcp6Dxe/Dhcp6Utility.c
index 2525a32..a65ed6d 100644
--- a/NetworkPkg/Dhcp6Dxe/Dhcp6Utility.c
+++ b/NetworkPkg/Dhcp6Dxe/Dhcp6Utility.c
@@ -2,7 +2,7 @@
Dhcp6 support functions implementation.
(C) Copyright 2015 Hewlett-Packard Development Company, L.P.<BR>
- Copyright (c) 2009 - 2014, Intel Corporation. All rights reserved.<BR>
+ Copyright (c) 2009 - 2017, Intel Corporation. All rights reserved.<BR>
This program and the accompanying materials
are licensed and made available under the terms and conditions of the BSD License
@@ -64,7 +64,7 @@ Dhcp6GenerateClientId (
//
// If System UUID is found from SMBIOS Table, use DUID-UUID type.
//
- if ((PcdGet8 (PcdDhcp6UidType) == Dhcp6DuidTypeUuid) && !EFI_ERROR (NetLibGetSystemGuid (&Uuid))) {
+ if ((PcdGet8 (PcdDhcp6UidType) == Dhcp6DuidTypeUuid) && !EFI_ERROR (NetLibGetSystemGuid (&Uuid)) && !CompareGuid (&Uuid, &gZeroGuid)) {
//
//
// The format of DUID-UUID: