diff --git a/MdePkg/Library/BasePeCoffLib/BasePeCoff.c b/MdePkg/Library/BasePeCoffLib/BasePeCoff.c index a534f52236..60f0470319 100644 --- a/MdePkg/Library/BasePeCoffLib/BasePeCoff.c +++ b/MdePkg/Library/BasePeCoffLib/BasePeCoff.c @@ -588,12 +588,10 @@ PeCoffLoaderRelocateImage ( if (NumberOfRvaAndSizes > EFI_IMAGE_DIRECTORY_ENTRY_BASERELOC) { RelocBase = PeCoffLoaderImageAddress (ImageContext, RelocDir->VirtualAddress); - ASSERT(RelocBase != NULL); RelocBaseEnd = PeCoffLoaderImageAddress ( ImageContext, RelocDir->VirtualAddress + RelocDir->Size - 1 ); - ASSERT(RelocBaseEnd !=NULL); } else { // // Set base and end to bypass processing below. @@ -628,7 +626,6 @@ PeCoffLoaderRelocateImage ( RelocEnd = (UINT16 *) ((CHAR8 *) RelocBase + RelocBase->SizeOfBlock); if (!(ImageContext->IsTeImage)) { FixupBase = PeCoffLoaderImageAddress (ImageContext, RelocBase->VirtualAddress); - ASSERT(FixupBase != NULL); } else { FixupBase = (CHAR8 *)(UINTN)(ImageContext->ImageAddress + RelocBase->VirtualAddress +