Make ASSERT statement more meaningful.

git-svn-id: https://edk2.svn.sourceforge.net/svnroot/edk2/trunk/edk2@9276 6f19259b-4bc3-4df7-8a09-765794883524
This commit is contained in:
lgao4 2009-09-17 01:57:24 +00:00
parent 14b21de964
commit db0b7ad5f4
2 changed files with 8 additions and 8 deletions

View File

@ -1120,11 +1120,11 @@ CoreStartImage (
return EFI_INVALID_PARAMETER; return EFI_INVALID_PARAMETER;
} }
if (!EFI_IMAGE_MACHINE_TYPE_SUPPORTED (Image->Machine)) {
// //
// The image to be started must have the machine type supported by DxeCore. // The image to be started must have the machine type supported by DxeCore.
// //
ASSERT (FALSE); ASSERT (EFI_IMAGE_MACHINE_TYPE_SUPPORTED (Image->Machine));
if (!EFI_IMAGE_MACHINE_TYPE_SUPPORTED (Image->Machine)) {
return EFI_UNSUPPORTED; return EFI_UNSUPPORTED;
} }

View File

@ -434,11 +434,11 @@ PeiLoadImage (
AuthenticationState AuthenticationState
); );
if (!EFI_ERROR (Status)) { if (!EFI_ERROR (Status)) {
if (!EFI_IMAGE_MACHINE_TYPE_SUPPORTED (PeCoffLoaderGetMachineType ((VOID *) (UINTN) ImageAddress))) {
// //
// The image to be started must have the machine type supported by PeiCore. // The image to be started must have the machine type supported by PeiCore.
// //
ASSERT (FALSE); ASSERT (EFI_IMAGE_MACHINE_TYPE_SUPPORTED (PeCoffLoaderGetMachineType ((VOID *) (UINTN) ImageAddress)));
if (!EFI_IMAGE_MACHINE_TYPE_SUPPORTED (PeCoffLoaderGetMachineType ((VOID *) (UINTN) ImageAddress))) {
return EFI_UNSUPPORTED; return EFI_UNSUPPORTED;
} }
return Status; return Status;