summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--MdePkg/Library/BasePeCoffLib/BasePeCoff.c8
1 files changed, 6 insertions, 2 deletions
diff --git a/MdePkg/Library/BasePeCoffLib/BasePeCoff.c b/MdePkg/Library/BasePeCoffLib/BasePeCoff.c
index 92285dfd05..f853c84827 100644
--- a/MdePkg/Library/BasePeCoffLib/BasePeCoff.c
+++ b/MdePkg/Library/BasePeCoffLib/BasePeCoff.c
@@ -1845,11 +1845,15 @@ PeCoffLoaderRelocateImageForRuntime (
}
if ((RelocBase == NULL) || (RelocBaseEnd == NULL) || ((UINTN)RelocBaseEnd < (UINTN)RelocBase)) {
- DEBUG ((DEBUG_ERROR, "Relocation block is not valid\n"));
+ //
+ // relocation block is not valid, just return
+ //
return;
}
} else {
- DEBUG ((DEBUG_ERROR, "Cannot find relocations, cannot continue to relocate the image\n"));
+ //
+ // Cannot find relocations, cannot continue to relocate the image, ASSERT for this invalid image.
+ //
ASSERT (FALSE);
return;
}