1. Fixed one bug in ConPlatform.c, add NULL judgment.

2. Fixed one type in UgaDraw.h.

git-svn-id: https://edk2.svn.sourceforge.net/svnroot/edk2/trunk/edk2@3976 6f19259b-4bc3-4df7-8a09-765794883524
This commit is contained in:
vanjeff 2007-09-29 02:57:38 +00:00
parent 327f4e7d26
commit c62a593c90
2 changed files with 42 additions and 45 deletions

View File

@ -739,8 +739,7 @@ Returns:
--*/
{
EFI_DEVICE_PATH_PROTOCOL *DevicePath;
EFI_DEVICE_PATH_PROTOCOL *TempDevicePath1;
EFI_DEVICE_PATH_PROTOCOL *TempDevicePath2;
EFI_DEVICE_PATH_PROTOCOL *TempDevicePath;
EFI_DEVICE_PATH_PROTOCOL *DevicePathInst;
UINTN Size;
@ -753,7 +752,7 @@ Returns:
//
// if performing Delete operation, the NewDevicePath must not be NULL.
//
TempDevicePath1 = NULL;
TempDevicePath = NULL;
DevicePath = Multi;
DevicePathInst = GetNextDevicePathInstance (&DevicePath, &Size);
@ -769,14 +768,10 @@ Returns:
}
} else {
if (Delete) {
TempDevicePath2 = AppendDevicePathInstance (
TempDevicePath1,
TempDevicePath = AppendDevicePathInstance (
NULL,
DevicePathInst
);
if (TempDevicePath1 != NULL) {
FreePool (TempDevicePath1);
}
TempDevicePath1 = TempDevicePath2;
}
}
@ -785,7 +780,7 @@ Returns:
}
if (Delete) {
*NewDevicePath = TempDevicePath1;
*NewDevicePath = TempDevicePath;
return EFI_SUCCESS;
}
@ -878,6 +873,7 @@ Returns:
return Status;
}
if (NewVariableDevicePath != NULL) {
Status = gRT->SetVariable (
VariableName,
&gEfiGlobalVariableGuid,
@ -887,6 +883,7 @@ Returns:
);
FreePool (NewVariableDevicePath);
}
return Status;
}

View File

@ -50,7 +50,7 @@ EFI_STATUS
;
/**
Return the current video mode information.
Set the current video mode information.
@param This Protocol instance pointer.
@param HorizontalResolution Current video horizontal resolution in pixels