]> git.proxmox.com Git - mirror_edk2.git/commitdiff
Fix a potential issue to use FreePool() with NULL pointer.
authorqhuang8 <qhuang8@6f19259b-4bc3-4df7-8a09-765794883524>
Fri, 14 Aug 2009 05:37:38 +0000 (05:37 +0000)
committerqhuang8 <qhuang8@6f19259b-4bc3-4df7-8a09-765794883524>
Fri, 14 Aug 2009 05:37:38 +0000 (05:37 +0000)
git-svn-id: https://edk2.svn.sourceforge.net/svnroot/edk2/trunk/edk2@9068 6f19259b-4bc3-4df7-8a09-765794883524

MdeModulePkg/Universal/Disk/PartitionDxe/Mbr.c

index 393f538428d37b5005f02602ce67c6ec13fcc89b..37c12d365aed106739efcefee8bb22fb56140393 100644 (file)
@@ -11,7 +11,7 @@
         always on the first sector of a media. The first sector also contains\r
         the legacy boot strap code.\r
 \r
-Copyright (c) 2006 - 2008, Intel Corporation. <BR>\r
+Copyright (c) 2006 - 2009, Intel Corporation. <BR>\r
 All rights reserved. This program and the accompanying materials\r
 are licensed and made available under the terms and conditions of the BSD License\r
 which accompanies this distribution.  The full text of the license may be found at\r
@@ -136,7 +136,7 @@ PartitionInstallMbrChildHandles (
 \r
   Mbr             = AllocatePool (BlockIo->Media->BlockSize);\r
   if (Mbr == NULL) {\r
-    goto Done;\r
+    return Found;\r
   }\r
 \r
   Status = DiskIo->ReadDisk (\r