From 9ee135501b7138126e537adc58352c4126c33fcb Mon Sep 17 00:00:00 2001 From: Laszlo Ersek Date: Sat, 7 Sep 2019 15:13:39 +0200 Subject: MdeModulePkg: PEI Core: clean up "AprioriFile" handling in FindFileEx() Clean up two issues around FindFileEx(): - The "AprioriFile" parameter's type differs between the function declaration and the function definition. The correct type is (EFI_PEI_FILE_HANDLE*). - "FfsFileHeader" has type (EFI_FFS_FILE_HEADER*); for clarity, we should cast it explicitly to EFI_PEI_FILE_HANDLE when assigning it to (*AprioriFile). This is a semantic cleanup, there is no functional change. Cc: Dandan Bi Cc: Hao A Wu Cc: Jian J Wang Cc: Liming Gao Signed-off-by: Laszlo Ersek Reviewed-by: Dandan Bi Reviewed-by: Philippe Mathieu-Daude Reviewed-by: Hao A Wu --- MdeModulePkg/Core/Pei/FwVol/FwVol.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'MdeModulePkg/Core/Pei/FwVol/FwVol.c') diff --git a/MdeModulePkg/Core/Pei/FwVol/FwVol.c b/MdeModulePkg/Core/Pei/FwVol/FwVol.c index 709db00694..f4642c47c1 100644 --- a/MdeModulePkg/Core/Pei/FwVol/FwVol.c +++ b/MdeModulePkg/Core/Pei/FwVol/FwVol.c @@ -407,7 +407,7 @@ FindFileEx ( } else if (AprioriFile != NULL) { if (FfsFileHeader->Type == EFI_FV_FILETYPE_FREEFORM) { if (CompareGuid (&FfsFileHeader->Name, &gPeiAprioriFileNameGuid)) { - *AprioriFile = FfsFileHeader; + *AprioriFile = (EFI_PEI_FILE_HANDLE)FfsFileHeader; } } } -- cgit v1.2.3