Temporary regression fix

Reverting a check added in A66, fixing #368
This commit is contained in:
Nikolaj Schlej 2023-06-23 21:12:14 -07:00
parent 8e710e637a
commit 2b8b00d5b0

View File

@ -1159,12 +1159,6 @@ USTATUS FfsParser::parseVolumeHeader(const UByteArray & volume, const UINT32 loc
(msgInvalidChecksum ? usprintf(", invalid, should be %04Xh", calculated) : UString(", valid")); (msgInvalidChecksum ? usprintf(", invalid, should be %04Xh", calculated) : UString(", valid"));
// Extended header present // Extended header present
// volumeHeader->ExtHeaderOffset should be aligned to 4 bytes
if (volumeHeader->ExtHeaderOffset % 4) {
msg(usprintf("%s: ExtHeaderOffset %04Xh (%hu) is not aligned by 4 bytes", __FUNCTION__, volumeHeader->ExtHeaderOffset, volumeHeader->ExtHeaderOffset));
return U_INVALID_VOLUME;
}
if (volumeHeader->Revision > 1 && volumeHeader->ExtHeaderOffset) { if (volumeHeader->Revision > 1 && volumeHeader->ExtHeaderOffset) {
if ((UINT32)volume.size() < volumeHeader->ExtHeaderOffset + sizeof(EFI_FIRMWARE_VOLUME_EXT_HEADER)) { if ((UINT32)volume.size() < volumeHeader->ExtHeaderOffset + sizeof(EFI_FIRMWARE_VOLUME_EXT_HEADER)) {
return U_INVALID_VOLUME; return U_INVALID_VOLUME;