Code scrub for DxeCore

git-svn-id: https://edk2.svn.sourceforge.net/svnroot/edk2/trunk/edk2@5520 6f19259b-4bc3-4df7-8a09-765794883524
This commit is contained in:
qhuang8
2008-07-18 09:50:09 +00:00
parent ff61847ddc
commit e94a9ff727
25 changed files with 327 additions and 567 deletions

View File

@ -79,7 +79,7 @@ CoreOpenImageFile (
if (SourceBuffer != NULL) {
ImageFileHandle->Source = SourceBuffer;
ImageFileHandle->SourceSize = SourceSize;
*DeviceHandle = NULL;
*DeviceHandle = NULL;
CoreLocateDevicePath (&gEfiDevicePathProtocolGuid, FilePath, DeviceHandle);
if (SourceSize > 0) {
Status = EFI_SUCCESS;
@ -252,7 +252,7 @@ CoreOpenImageFile (
//
// Read the file into the buffer we allocated
//
ImageFileHandle->SourceSize = (UINTN)FileInfo->FileSize;
ImageFileHandle->SourceSize = (UINTN) FileInfo->FileSize;
ImageFileHandle->FreeBuffer = TRUE;
Status = FileHandle->Read (FileHandle, &ImageFileHandle->SourceSize, ImageFileHandle->Source);
@ -277,11 +277,11 @@ CoreOpenImageFile (
TempFilePath = *FilePath;
Status = CoreDevicePathToInterface (
&gEfiLoadFileProtocolGuid,
&TempFilePath,
(VOID*)&LoadFile,
DeviceHandle
);
&gEfiLoadFileProtocolGuid,
&TempFilePath,
(VOID*) &LoadFile,
DeviceHandle
);
if (!EFI_ERROR (Status)) {
//
// Call LoadFile with the correct buffer size
@ -333,7 +333,6 @@ Done:
/**
Read image file (specified by UserHandle) into user specified buffer with specified offset
and length.
@ -449,7 +448,6 @@ CoreGrowBuffer (
//
// If the status code is "buffer too small", resize the buffer
//
if (*Status == EFI_BUFFER_TOO_SMALL) {
if (*Buffer != NULL) {
CoreFreePool (*Buffer);