From: sfu5 Date: Thu, 1 Sep 2011 08:51:00 +0000 (+0000) Subject: Fix bug for UefiPxeBcDxe driver to catch the return status. X-Git-Tag: edk2-stable201903~14300 X-Git-Url: https://git.proxmox.com/?p=mirror_edk2.git;a=commitdiff_plain;h=ef2455b1755237cb0ffc6c13642fde216fbdc640;ds=sidebyside Fix bug for UefiPxeBcDxe driver to catch the return status. Signed-off-by: sfu5 Reviewed-by: hhuan13 Reviewed-by: xdu2 git-svn-id: https://edk2.svn.sourceforge.net/svnroot/edk2/trunk/edk2@12253 6f19259b-4bc3-4df7-8a09-765794883524 --- diff --git a/NetworkPkg/UefiPxeBcDxe/PxeBcImpl.c b/NetworkPkg/UefiPxeBcDxe/PxeBcImpl.c index 82fddb169a..ae81693bfb 100644 --- a/NetworkPkg/UefiPxeBcDxe/PxeBcImpl.c +++ b/NetworkPkg/UefiPxeBcDxe/PxeBcImpl.c @@ -669,7 +669,9 @@ EfiPxeBcDiscover ( ); } - if (!EFI_ERROR (Status)) { + if (EFI_ERROR (Status)) { + return Status; + } else { // // Parse the cached PXE reply packet, and store it into mode data if valid. // @@ -937,6 +939,10 @@ EfiPxeBcMtftp ( Mode->IcmpErrorReceived = TRUE; } + if (EFI_ERROR (Status)) { + return Status; + } + if (Mode->UsingIpv6) { Status = Private->Udp6Read->Configure (Private->Udp6Read, &Private->Udp6CfgData); } else {