diff options
author | James Lu <james.lu@intel.com> | 2022-07-10 22:05:31 -0700 |
---|---|---|
committer | mergify[bot] <37929162+mergify[bot]@users.noreply.github.com> | 2022-07-27 17:00:40 +0000 |
commit | 2677286307c67b62c198cf6890d62ec540dd8c99 (patch) | |
tree | 18583b8c8d3f7d7eac28d0ba4fc1b5c80d516edc /UefiPayloadPkg | |
parent | e3d468acb9ce26a75fee45d742619ac1c6683280 (diff) | |
download | edk2-2677286307c67b62c198cf6890d62ec540dd8c99.zip edk2-2677286307c67b62c198cf6890d62ec540dd8c99.tar.gz edk2-2677286307c67b62c198cf6890d62ec540dd8c99.tar.bz2 |
UefiPayloadPkg: Fix RelaAddress type always mismatch in if condition
REF: https://bugzilla.tianocore.org/show_bug.cgi?id=3984
Under function RolocateElfDynamic() in Elf32Lib.c
if (RelaAddress == MAX_UINT64) is always FALSE while RelaAddress is UINT32
Fix is to modify if condition check to "if (RelaAddress == MAX_UINT32)"
Cc: Ray Ni <ray.ni@intel.com>
Cc: Guo Dong <guo.dong@intel.com>
Cc: Gua Guo <gua.guo@intel.com>
Signed-off-by: James Lu <james.lu@intel.com>
Reviewed-by: Guo Dong <guo.dong@intel.com>
Diffstat (limited to 'UefiPayloadPkg')
-rw-r--r-- | UefiPayloadPkg/PayloadLoaderPeim/ElfLib/Elf32Lib.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/UefiPayloadPkg/PayloadLoaderPeim/ElfLib/Elf32Lib.c b/UefiPayloadPkg/PayloadLoaderPeim/ElfLib/Elf32Lib.c index b002c4b..cb915e7 100644 --- a/UefiPayloadPkg/PayloadLoaderPeim/ElfLib/Elf32Lib.c +++ b/UefiPayloadPkg/PayloadLoaderPeim/ElfLib/Elf32Lib.c @@ -292,7 +292,7 @@ RelocateElf32Dynamic ( }
}
- if (RelaAddress == MAX_UINT64) {
+ if (RelaAddress == MAX_UINT32) {
ASSERT (RelaCount == 0);
ASSERT (RelaEntrySize == 0);
ASSERT (RelaSize == 0);
|