Add more check for local FileInfo variable before it is used.
authorlgao4 <lgao4@6f19259b-4bc3-4df7-8a09-765794883524>
Wed, 2 Dec 2009 10:13:24 +0000 (10:13 +0000)
committerlgao4 <lgao4@6f19259b-4bc3-4df7-8a09-765794883524>
Wed, 2 Dec 2009 10:13:24 +0000 (10:13 +0000)
git-svn-id: https://edk2.svn.sourceforge.net/svnroot/edk2/trunk/edk2@9506 6f19259b-4bc3-4df7-8a09-765794883524

MdePkg/Library/DxeServicesLib/DxeServicesLib.c

index 107bf4bd62790507bce991127d27691aca7e6cd5..45936d4abf2c557b056c4dda7df9c7032646350e 100644 (file)
@@ -617,7 +617,7 @@ GetFileBufferByFilePath (
             }\r
           }\r
           \r
-          if (!EFI_ERROR (Status)) {\r
+          if (!EFI_ERROR (Status) && (FileInfo != NULL)) {\r
             //\r
             // Allocate space for the file\r
             //\r