]> git.proxmox.com Git - mirror_edk2.git/commitdiff
Minor code enhancement.
authorxli24 <xli24@6f19259b-4bc3-4df7-8a09-765794883524>
Tue, 12 Jan 2010 03:30:58 +0000 (03:30 +0000)
committerxli24 <xli24@6f19259b-4bc3-4df7-8a09-765794883524>
Tue, 12 Jan 2010 03:30:58 +0000 (03:30 +0000)
git-svn-id: https://edk2.svn.sourceforge.net/svnroot/edk2/trunk/edk2@9711 6f19259b-4bc3-4df7-8a09-765794883524

IntelFrameworkModulePkg/Library/GenericBdsLib/BdsMisc.c

index f937be27a618d81a8accffe787379d326f7badf2..351dfd59139b220b11ebf796058d2d21d1b22988 100644 (file)
@@ -1,7 +1,7 @@
 /** @file\r
   Misc BDS library function\r
 \r
 /** @file\r
   Misc BDS library function\r
 \r
-Copyright (c) 2004 - 2008, Intel Corporation. <BR>\r
+Copyright (c) 2004 - 2010, 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
 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
@@ -1006,11 +1006,12 @@ BdsLibGetImageHeader (
     Root = NULL;\r
     goto Done;\r
   }\r
     Root = NULL;\r
     goto Done;\r
   }\r
-\r
+  ASSERT (Root != NULL);\r
   Status = Root->Open (Root, &ThisFile, FileName, EFI_FILE_MODE_READ, 0);\r
   if (EFI_ERROR (Status)) {\r
     goto Done;\r
   }\r
   Status = Root->Open (Root, &ThisFile, FileName, EFI_FILE_MODE_READ, 0);\r
   if (EFI_ERROR (Status)) {\r
     goto Done;\r
   }\r
+  ASSERT (ThisFile != NULL);\r
 \r
   //\r
   // Get file size\r
 \r
   //\r
   // Get file size\r