summaryrefslogtreecommitdiffstats
path: root/MdeModulePkg
diff options
context:
space:
mode:
authorqhuang8 <qhuang8@6f19259b-4bc3-4df7-8a09-765794883524>2009-08-14 05:37:38 +0000
committerqhuang8 <qhuang8@6f19259b-4bc3-4df7-8a09-765794883524>2009-08-14 05:37:38 +0000
commit737dfc361211ac91b7465fccbbf5fbeff1ed5466 (patch)
treef10b39835383bac15944f428ec370cae7d928332 /MdeModulePkg
parentdb63aeea6d3f0ea56f20d1bdf455093e60266d5f (diff)
downloadedk2-737dfc361211ac91b7465fccbbf5fbeff1ed5466.tar.gz
edk2-737dfc361211ac91b7465fccbbf5fbeff1ed5466.tar.bz2
edk2-737dfc361211ac91b7465fccbbf5fbeff1ed5466.zip
Fix a potential issue to use FreePool() with NULL pointer.
git-svn-id: https://edk2.svn.sourceforge.net/svnroot/edk2/trunk/edk2@9068 6f19259b-4bc3-4df7-8a09-765794883524
Diffstat (limited to 'MdeModulePkg')
-rw-r--r--MdeModulePkg/Universal/Disk/PartitionDxe/Mbr.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/MdeModulePkg/Universal/Disk/PartitionDxe/Mbr.c b/MdeModulePkg/Universal/Disk/PartitionDxe/Mbr.c
index 393f538428..37c12d365a 100644
--- a/MdeModulePkg/Universal/Disk/PartitionDxe/Mbr.c
+++ b/MdeModulePkg/Universal/Disk/PartitionDxe/Mbr.c
@@ -11,7 +11,7 @@
always on the first sector of a media. The first sector also contains
the legacy boot strap code.
-Copyright (c) 2006 - 2008, Intel Corporation. <BR>
+Copyright (c) 2006 - 2009, Intel Corporation. <BR>
All rights reserved. This program and the accompanying materials
are licensed and made available under the terms and conditions of the BSD License
which accompanies this distribution. The full text of the license may be found at
@@ -136,7 +136,7 @@ PartitionInstallMbrChildHandles (
Mbr = AllocatePool (BlockIo->Media->BlockSize);
if (Mbr == NULL) {
- goto Done;
+ return Found;
}
Status = DiskIo->ReadDisk (