diff options
Diffstat (limited to 'EmbeddedPkg')
-rw-r--r-- | EmbeddedPkg/Library/PrePiLib/FwVol.c | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/EmbeddedPkg/Library/PrePiLib/FwVol.c b/EmbeddedPkg/Library/PrePiLib/FwVol.c index f73f1c0da4..530fc15dca 100644 --- a/EmbeddedPkg/Library/PrePiLib/FwVol.c +++ b/EmbeddedPkg/Library/PrePiLib/FwVol.c @@ -209,6 +209,9 @@ FindFileEx ( FfsFileHeader = (EFI_FFS_FILE_HEADER *)((UINT8 *)*FileHeader + FileOccupiedSize);
}
+ // FFS files begin with a header that is aligned on an 8-byte boundary
+ FfsFileHeader = ALIGN_POINTER (FfsFileHeader, 8);
+
FileOffset = (UINT32) ((UINT8 *)FfsFileHeader - (UINT8 *)FwVolHeader);
ASSERT (FileOffset <= 0xFFFFFFFF);
|