mirror of
https://github.com/acidanthera/audk.git
synced 2025-07-25 22:54:51 +02:00
To fix,
1662 Graphics Console Driver: No checking for invalid parameter in SetMode() 8588 Graphic Console should not chech PixelFormat for 800*600 resolution git-svn-id: https://edk2.svn.sourceforge.net/svnroot/edk2/trunk/edk2@2242 6f19259b-4bc3-4df7-8a09-765794883524
This commit is contained in:
parent
fb610f2ac1
commit
e313deb992
@ -378,9 +378,7 @@ GraphicsConsoleControllerDriverStart (
|
|||||||
);
|
);
|
||||||
if (!EFI_ERROR (Status)) {
|
if (!EFI_ERROR (Status)) {
|
||||||
if ((Info->HorizontalResolution == 800) &&
|
if ((Info->HorizontalResolution == 800) &&
|
||||||
(Info->VerticalResolution == 600) &&
|
(Info->VerticalResolution == 600)) {
|
||||||
((Info->PixelFormat == PixelRedGreenBlueReserved8BitPerColor) ||
|
|
||||||
(Info->PixelFormat == PixelBlueGreenRedReserved8BitPerColor))) {
|
|
||||||
Status = Private->GraphicsOutput->SetMode (Private->GraphicsOutput, ModeNumber);
|
Status = Private->GraphicsOutput->SetMode (Private->GraphicsOutput, ModeNumber);
|
||||||
if (!EFI_ERROR (Status)) {
|
if (!EFI_ERROR (Status)) {
|
||||||
gBS->FreePool (Info);
|
gBS->FreePool (Info);
|
||||||
@ -1164,6 +1162,10 @@ GraphicsConsoleConOutSetMode (
|
|||||||
UgaDraw = Private->UgaDraw;
|
UgaDraw = Private->UgaDraw;
|
||||||
ModeData = &(Private->ModeData[ModeNumber]);
|
ModeData = &(Private->ModeData[ModeNumber]);
|
||||||
|
|
||||||
|
if (ModeData->Columns <= 0 && ModeData->Rows <= 0) {
|
||||||
|
return EFI_UNSUPPORTED;
|
||||||
|
}
|
||||||
|
|
||||||
//
|
//
|
||||||
// Make sure the requested mode number is supported
|
// Make sure the requested mode number is supported
|
||||||
//
|
//
|
||||||
|
Loading…
x
Reference in New Issue
Block a user