diff --git a/EdkCompatibilityPkg/Compatibility/FrameworkHiiToUefiHiiThunk/UefiIfrParser.c b/EdkCompatibilityPkg/Compatibility/FrameworkHiiToUefiHiiThunk/UefiIfrParser.c index 6c7d19c2cd..8870128ad2 100644 --- a/EdkCompatibilityPkg/Compatibility/FrameworkHiiToUefiHiiThunk/UefiIfrParser.c +++ b/EdkCompatibilityPkg/Compatibility/FrameworkHiiToUefiHiiThunk/UefiIfrParser.c @@ -979,7 +979,7 @@ ParseOpCodes ( // // check the formset GUID // - if (CompareGuid ((EFI_GUID *)(VOID *)&FormSet->Guid, (EFI_GUID *)(VOID *)&((EFI_IFR_FORM_SET *) OpCodeData)->Guid) != 0) { + if (!CompareGuid ((EFI_GUID *)(VOID *)&FormSet->Guid, (EFI_GUID *)(VOID *)&((EFI_IFR_FORM_SET *) OpCodeData)->Guid)) { return EFI_INVALID_PARAMETER; } diff --git a/EdkCompatibilityPkg/Compatibility/FrameworkHiiToUefiHiiThunk/Utility.c b/EdkCompatibilityPkg/Compatibility/FrameworkHiiToUefiHiiThunk/Utility.c index 810e3aff8f..4934b2b3f4 100644 --- a/EdkCompatibilityPkg/Compatibility/FrameworkHiiToUefiHiiThunk/Utility.c +++ b/EdkCompatibilityPkg/Compatibility/FrameworkHiiToUefiHiiThunk/Utility.c @@ -344,7 +344,7 @@ GetAttributesOfFirstFormSet ( case EFI_IFR_GUID_OP: Class = (EFI_IFR_GUID_CLASS*) OpCode; - if (CompareGuid ((EFI_GUID *)(VOID *)&Class->Guid, &gTianoHiiIfrGuid) == 0) { + if (CompareGuid ((EFI_GUID *)(VOID *)&Class->Guid, &gTianoHiiIfrGuid)) { Class = (EFI_IFR_GUID_CLASS *) OpCode; switch (Class->ExtendOpCode) { @@ -497,7 +497,7 @@ CreateQuestionIdMap ( case EFI_IFR_GUID_OP: OptionMap = (EFI_IFR_GUID_OPTIONKEY *) OpCode; - if (CompareGuid ((EFI_GUID *)(VOID *)&OptionMap->Guid, &gFrameworkHiiCompatbilityGuid) == 0) { + if (CompareGuid ((EFI_GUID *)(VOID *)&OptionMap->Guid, &gFrameworkHiiCompatbilityGuid)) { if (OptionMap->ExtendOpCode == EFI_IFR_EXTEND_OP_OPTIONKEY) { OneOfOptinMapEntryListHead = GetOneOfOptionMapEntryListHead (ThunkContext, OptionMap->QuestionId); if (OneOfOptinMapEntryListHead == NULL) { @@ -525,7 +525,7 @@ CreateQuestionIdMap ( InsertTailList (OneOfOptinMapEntryListHead, &OneOfOptionMapEntry->Link); } - } else if (CompareGuid ((EFI_GUID *)(VOID *)&OptionMap->Guid, &gTianoHiiIfrGuid) == 0) { + } else if (CompareGuid ((EFI_GUID *)(VOID *)&OptionMap->Guid, &gTianoHiiIfrGuid)) { Class = (EFI_IFR_GUID_CLASS *) OpCode; switch (Class->ExtendOpCode) {