diff options
author | sfu5 <sfu5@6f19259b-4bc3-4df7-8a09-765794883524> | 2012-02-07 05:31:11 +0000 |
---|---|---|
committer | sfu5 <sfu5@6f19259b-4bc3-4df7-8a09-765794883524> | 2012-02-07 05:31:11 +0000 |
commit | d40002bab9958da3439a2548aa3003d8d68672ff (patch) | |
tree | ea0b8de01b0f93833687be089c0700ee3c565745 /NetworkPkg/UefiPxeBcDxe/PxeBcImpl.c | |
parent | b4ebbafff696b02c69ee3a6d293a39f9a7c2f58d (diff) | |
download | edk2-platforms-d40002bab9958da3439a2548aa3003d8d68672ff.tar.xz |
1. Fix a bug for PXEv6 when Proxy PXE server and DHCP server are located at the same server.
Signed-off-by: sfu5
Reviewed-by: tye
Reviewed-by: qianouyang
git-svn-id: https://edk2.svn.sourceforge.net/svnroot/edk2/trunk/edk2@12985 6f19259b-4bc3-4df7-8a09-765794883524
Diffstat (limited to 'NetworkPkg/UefiPxeBcDxe/PxeBcImpl.c')
-rw-r--r-- | NetworkPkg/UefiPxeBcDxe/PxeBcImpl.c | 10 |
1 files changed, 7 insertions, 3 deletions
diff --git a/NetworkPkg/UefiPxeBcDxe/PxeBcImpl.c b/NetworkPkg/UefiPxeBcDxe/PxeBcImpl.c index 67abd48f4c..ba7f948594 100644 --- a/NetworkPkg/UefiPxeBcDxe/PxeBcImpl.c +++ b/NetworkPkg/UefiPxeBcDxe/PxeBcImpl.c @@ -1,7 +1,7 @@ /** @file
This implementation of EFI_PXE_BASE_CODE_PROTOCOL and EFI_LOAD_FILE_PROTOCOL.
- Copyright (c) 2007 - 2011, Intel Corporation. All rights reserved.<BR>
+ Copyright (c) 2007 - 2012, 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
@@ -1378,7 +1378,9 @@ EfiPxeBcUdpRead ( if (Udp6Rx->DataLength - HeaderLen > *BufferSize) {
Status = EFI_BUFFER_TOO_SMALL;
} else {
- *HeaderSize = HeaderLen;
+ if (HeaderSize != NULL) {
+ *HeaderSize = HeaderLen;
+ }
*BufferSize = Udp6Rx->DataLength - HeaderLen;
HeaderCopiedLen = 0;
@@ -1430,7 +1432,9 @@ EfiPxeBcUdpRead ( if (Udp4Rx->DataLength - HeaderLen > *BufferSize) {
Status = EFI_BUFFER_TOO_SMALL;
} else {
- *HeaderSize = HeaderLen;
+ if (HeaderSize != NULL) {
+ *HeaderSize = HeaderLen;
+ }
*BufferSize = Udp4Rx->DataLength - HeaderLen;
HeaderCopiedLen = 0;
|