mirror of
https://github.com/acidanthera/audk.git
synced 2025-07-26 23:24:03 +02:00
BaseTools/VolInfo: Fix EFI_SECTION_GUID_DEFINED parsing
Currently 'PutFileImage' function is called with arguments that are not advanced on each section parsing. This would lead to an error if EFI_SECTION_GUID_DEFINED is not the first in a file. The same mistake is present in the parsing of CRC32 guided section case. Use correct arguments to fix the issue. Signed-off-by: Konstantin Aladyshev <aladyshev22@gmail.com> Reviewed-by: Bob Feng <bob.c.feng@intel.com> Reviewed-by: Liming Gao <gaoliming@byosoft.com.cn>
This commit is contained in:
parent
9fc029ee62
commit
8be33c6544
@ -2019,8 +2019,8 @@ Returns:
|
|||||||
Status =
|
Status =
|
||||||
PutFileImage (
|
PutFileImage (
|
||||||
ToolInputFile,
|
ToolInputFile,
|
||||||
(CHAR8*) SectionBuffer + DataOffset,
|
(CHAR8*)Ptr + DataOffset,
|
||||||
BufferLength - DataOffset
|
SectionLength - DataOffset
|
||||||
);
|
);
|
||||||
|
|
||||||
system (SystemCommand);
|
system (SystemCommand);
|
||||||
@ -2065,8 +2065,8 @@ Returns:
|
|||||||
//
|
//
|
||||||
printf ("/------------ Encapsulation section start -----------------\\\n");
|
printf ("/------------ Encapsulation section start -----------------\\\n");
|
||||||
Status = ParseSection (
|
Status = ParseSection (
|
||||||
SectionBuffer + DataOffset,
|
Ptr + DataOffset,
|
||||||
BufferLength - DataOffset
|
SectionLength - DataOffset
|
||||||
);
|
);
|
||||||
if (EFI_ERROR (Status)) {
|
if (EFI_ERROR (Status)) {
|
||||||
Error (NULL, 0, 0003, "parse of CRC32 GUIDED section failed", NULL);
|
Error (NULL, 0, 0003, "parse of CRC32 GUIDED section failed", NULL);
|
||||||
|
Loading…
x
Reference in New Issue
Block a user