Revision: 14137
http://edk2.svn.sourceforge.net/edk2/?rev=14137&view=rev
Author: sfu5
Date: 2013-02-20 08:20:14 +0000 (Wed, 20 Feb 2013)
Log Message:
-----------
Remove the useless goto statements in PXE driver.
Signed-off-by: Fu Siyuan <[email protected]>
Reviewed-by: Ye Ting <[email protected]>
Reviewed-by: Ouyang Qian <[email protected]>
Modified Paths:
--------------
trunk/edk2/NetworkPkg/UefiPxeBcDxe/PxeBcImpl.c
trunk/edk2/NetworkPkg/UefiPxeBcDxe/PxeBcSupport.c
Modified: trunk/edk2/NetworkPkg/UefiPxeBcDxe/PxeBcImpl.c
===================================================================
--- trunk/edk2/NetworkPkg/UefiPxeBcDxe/PxeBcImpl.c 2013-02-20 03:38:10 UTC
(rev 14136)
+++ trunk/edk2/NetworkPkg/UefiPxeBcDxe/PxeBcImpl.c 2013-02-20 08:20:14 UTC
(rev 14137)
@@ -1,7 +1,7 @@
/** @file
This implementation of EFI_PXE_BASE_CODE_PROTOCOL and EFI_LOAD_FILE_PROTOCOL.
- Copyright (c) 2007 - 2012, Intel Corporation. All rights reserved.<BR>
+ Copyright (c) 2007 - 2013, 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
@@ -428,10 +428,6 @@
// Start S.A.R.R. process to get a IPv6 address and other boot information.
//
Status = PxeBcDhcp6Sarr (Private, Private->Dhcp6);
-
- if (EFI_ERROR (Status)) {
- goto ON_EXIT;
- }
} else {
//
@@ -443,13 +439,11 @@
// Start D.O.R.A. process to get a IPv4 address and other boot information.
//
Status = PxeBcDhcp4Dora (Private, Private->Dhcp4);
-
- if (EFI_ERROR (Status)) {
- goto ON_EXIT;
- }
}
-
-ON_EXIT:
+
+ //
+ // Reconfigure the UDP instance with the default configuration.
+ //
if (Mode->UsingIpv6) {
Private->Udp6Read->Configure (Private->Udp6Read, &Private->Udp6CfgData);
} else {
@@ -690,9 +684,7 @@
}
}
- if (EFI_ERROR (Status)) {
- goto ON_EXIT;
- } else {
+ if (!EFI_ERROR (Status)) {
//
// Parse the cached PXE reply packet, and store it into mode data if valid.
//
@@ -964,11 +956,9 @@
Mode->IcmpErrorReceived = TRUE;
}
- if (EFI_ERROR (Status)) {
- goto ON_EXIT;
- }
-
-ON_EXIT:
+ //
+ // Reconfigure the UDP instance with the default configuration.
+ //
if (Mode->UsingIpv6) {
Private->Udp6Read->Configure (Private->Udp6Read, &Private->Udp6CfgData);
} else {
Modified: trunk/edk2/NetworkPkg/UefiPxeBcDxe/PxeBcSupport.c
===================================================================
--- trunk/edk2/NetworkPkg/UefiPxeBcDxe/PxeBcSupport.c 2013-02-20 03:38:10 UTC
(rev 14136)
+++ trunk/edk2/NetworkPkg/UefiPxeBcDxe/PxeBcSupport.c 2013-02-20 08:20:14 UTC
(rev 14137)
@@ -1,7 +1,7 @@
/** @file
Support functions implementation for UefiPxeBc Driver.
- Copyright (c) 2007 - 2011, Intel Corporation. All rights reserved.<BR>
+ Copyright (c) 2007 - 2013, 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
@@ -59,10 +59,6 @@
}
Status = Private->Ip6->Receive (Private->Ip6, &Private->Icmp6Token);
- if (EFI_ERROR (Status)) {
- goto ON_EXIT;
- }
-
} else {
ASSERT (SubnetMask != NULL);
CopyMem (&Private->Udp4CfgData.StationAddress, StationIp, sizeof
(EFI_IPv4_ADDRESS));
@@ -82,10 +78,6 @@
}
Status = Private->Ip4->Receive (Private->Ip4, &Private->IcmpToken);
- if (EFI_ERROR (Status)) {
- goto ON_EXIT;
- }
-
}
ON_EXIT:
This was sent by the SourceForge.net collaborative development platform, the
world's largest Open Source development site.
------------------------------------------------------------------------------
Everyone hates slow websites. So do we.
Make your web apps faster with AppDynamics
Download AppDynamics Lite for free today:
http://p.sf.net/sfu/appdyn_d2d_feb
_______________________________________________
edk2-commits mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/edk2-commits