diff options
author | xdu2 <xdu2@6f19259b-4bc3-4df7-8a09-765794883524> | 2011-10-26 06:52:02 +0000 |
---|---|---|
committer | xdu2 <xdu2@6f19259b-4bc3-4df7-8a09-765794883524> | 2011-10-26 06:52:02 +0000 |
commit | e20d6513edbdd12114558969baea0fc3fa829b0f (patch) | |
tree | fc98f1618824b530f5db5bc2a501d6be6cf4395d /MdeModulePkg | |
parent | 042a73f51b97ec9e14d91ee47617ea1fb24ede06 (diff) | |
download | edk2-platforms-e20d6513edbdd12114558969baea0fc3fa829b0f.tar.xz |
MdeModulePkg: Enhance error handling in NetLibGetMacAddress() of DxeNetLib.
Signed-off-by: xdu2
Reviewed-by: vanjeff
git-svn-id: https://edk2.svn.sourceforge.net/svnroot/edk2/trunk/edk2@12572 6f19259b-4bc3-4df7-8a09-765794883524
Diffstat (limited to 'MdeModulePkg')
-rw-r--r-- | MdeModulePkg/Library/DxeNetLib/DxeNetLib.c | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/MdeModulePkg/Library/DxeNetLib/DxeNetLib.c b/MdeModulePkg/Library/DxeNetLib/DxeNetLib.c index dbd77e5bda..82322c98c8 100644 --- a/MdeModulePkg/Library/DxeNetLib/DxeNetLib.c +++ b/MdeModulePkg/Library/DxeNetLib/DxeNetLib.c @@ -2130,6 +2130,7 @@ NetLibGetMacAddress ( (VOID **) &Mnp
);
if (EFI_ERROR (Status)) {
+ MnpSb->DestroyChild (MnpSb, MnpChildHandle);
return Status;
}
@@ -2138,6 +2139,7 @@ NetLibGetMacAddress ( //
Status = Mnp->GetModeData (Mnp, NULL, &SnpModeData);
if (EFI_ERROR (Status)) {
+ MnpSb->DestroyChild (MnpSb, MnpChildHandle);
return Status;
}
SnpMode = &SnpModeData;
|