]> git.proxmox.com Git - mirror_edk2.git/commitdiff
GraphicsOutputBlt() need judge parameter
authorklu2 <klu2@6f19259b-4bc3-4df7-8a09-765794883524>
Thu, 11 Feb 2010 05:53:06 +0000 (05:53 +0000)
committerklu2 <klu2@6f19259b-4bc3-4df7-8a09-765794883524>
Thu, 11 Feb 2010 05:53:06 +0000 (05:53 +0000)
git-svn-id: https://edk2.svn.sourceforge.net/svnroot/edk2/trunk/edk2@9985 6f19259b-4bc3-4df7-8a09-765794883524

MdeModulePkg/Universal/Console/ConSplitterDxe/ConSplitterGraphics.c

index f01e0a7b8dbec00655804d08018585c2e970cd65..5b11f2114b211e37a7e9987ec2b78491018bdbe8 100644 (file)
@@ -1,7 +1,7 @@
 /** @file\r
   Support for Graphics output spliter.\r
   \r
-Copyright (c) 2006 - 2009, Intel Corporation. <BR>\r
+Copyright (c) 2006 - 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
@@ -239,6 +239,10 @@ ConSplitterGraphicsOutputBlt (
   EFI_GRAPHICS_OUTPUT_PROTOCOL    *GraphicsOutput;\r
   EFI_UGA_DRAW_PROTOCOL           *UgaDraw;\r
 \r
+  if (This == NULL || ((UINTN) BltOperation) >= EfiGraphicsOutputBltOperationMax) {\r
+    return EFI_INVALID_PARAMETER;\r
+  }\r
+  \r
   Private = GRAPHICS_OUTPUT_SPLITTER_PRIVATE_DATA_FROM_THIS (This);\r
 \r
   ReturnStatus = EFI_SUCCESS;\r