diff options
author | jljusten <jljusten@6f19259b-4bc3-4df7-8a09-765794883524> | 2008-04-24 16:21:53 +0000 |
---|---|---|
committer | jljusten <jljusten@6f19259b-4bc3-4df7-8a09-765794883524> | 2008-04-24 16:21:53 +0000 |
commit | 4cb43192bd4a7b7eee05f5c33233459843636edb (patch) | |
tree | 848afdd6c229a825d9976b8ba56e797deda48be6 /EdkCompatibilityPkg/Foundation/Library/Dxe/UefiEfiIfrSupportLib/UefiIfrOpCodeCreation.c | |
parent | 8067d3032cae5a13d0f2ab045eb8064ba4c1ee52 (diff) | |
download | edk2-platforms-4cb43192bd4a7b7eee05f5c33233459843636edb.tar.xz |
Fix various warnings with the Intel C compiler.
EfiBind.h:
* Adding ignores for certain warnings with the Intel C compiler.
(Partially merged from MdePkg.)
EfiPxe.h:
* Make sure PXE_NO_UINT64_SUPPORT is defined
Decompress.c:
* Removed 'unreachable' return statement.
EdkCompatibilityPkg/**: (all other files)
* Remove trailing comma from last value in enum.
* Include <EfiBind.h> instead of "EfiBind.h", or
for some reason __STDC_VERSION__ is not defined.
* Introduce more explicit function call ordering by
storing results in local variables before using
in a calculation.
* Add some additional casting for BOOLEAN & UINT8
following calculations which change the type to 'int'.
git-svn-id: https://edk2.svn.sourceforge.net/svnroot/edk2/trunk/edk2@5123 6f19259b-4bc3-4df7-8a09-765794883524
Diffstat (limited to 'EdkCompatibilityPkg/Foundation/Library/Dxe/UefiEfiIfrSupportLib/UefiIfrOpCodeCreation.c')
-rw-r--r-- | EdkCompatibilityPkg/Foundation/Library/Dxe/UefiEfiIfrSupportLib/UefiIfrOpCodeCreation.c | 12 |
1 files changed, 6 insertions, 6 deletions
diff --git a/EdkCompatibilityPkg/Foundation/Library/Dxe/UefiEfiIfrSupportLib/UefiIfrOpCodeCreation.c b/EdkCompatibilityPkg/Foundation/Library/Dxe/UefiEfiIfrSupportLib/UefiIfrOpCodeCreation.c index 3729fa216f..56463266d1 100644 --- a/EdkCompatibilityPkg/Foundation/Library/Dxe/UefiEfiIfrSupportLib/UefiIfrOpCodeCreation.c +++ b/EdkCompatibilityPkg/Foundation/Library/Dxe/UefiEfiIfrSupportLib/UefiIfrOpCodeCreation.c @@ -32,7 +32,7 @@ IsValidQuestionFlags ( IN UINT8 Flags
)
{
- return (Flags & (~QUESTION_FLAGS)) ? FALSE : TRUE;
+ return (BOOLEAN)((Flags & (~QUESTION_FLAGS)) ? FALSE : TRUE);
}
STATIC
@@ -41,7 +41,7 @@ IsValidValueType ( IN UINT8 Type
)
{
- return (Type <= EFI_IFR_TYPE_OTHER) ? TRUE : FALSE;
+ return (BOOLEAN)((Type <= EFI_IFR_TYPE_OTHER) ? TRUE : FALSE);
}
STATIC
@@ -67,7 +67,7 @@ IsValidCheckboxFlags ( IN UINT8 Flags
)
{
- return (Flags <= EFI_IFR_CHECKBOX_DEFAULT_MFG) ? TRUE : FALSE;
+ return (BOOLEAN)((Flags <= EFI_IFR_CHECKBOX_DEFAULT_MFG) ? TRUE : FALSE);
}
EFI_STATUS
@@ -302,7 +302,7 @@ CreateOneOfOptionOpCode ( OneOfOption.Option = OptionsList[Index].StringToken;
OneOfOption.Value = OptionsList[Index].Value;
- OneOfOption.Flags = OptionsList[Index].Flags & (EFI_IFR_OPTION_DEFAULT | EFI_IFR_OPTION_DEFAULT_MFG);
+ OneOfOption.Flags = (UINT8)(OptionsList[Index].Flags & (EFI_IFR_OPTION_DEFAULT | EFI_IFR_OPTION_DEFAULT_MFG));
OneOfOption.Type = Type;
LocalBuffer = (UINT8 *) Data->Data + Data->Offset;
@@ -360,7 +360,7 @@ CreateOneOfOpCode ( EfiCopyMem (LocalBuffer, &OneOf, sizeof (EFI_IFR_ONE_OF));
Data->Offset += sizeof (EFI_IFR_ONE_OF);
- CreateOneOfOptionOpCode (OptionCount, OptionsList, (OneOfFlags & EFI_IFR_NUMERIC_SIZE), Data);
+ CreateOneOfOptionOpCode (OptionCount, OptionsList, (UINT8)(OneOfFlags & EFI_IFR_NUMERIC_SIZE), Data);
CreateEndOpCode (Data);
@@ -549,7 +549,7 @@ CreateNumericOpCode ( Data->Offset += sizeof (EFI_IFR_NUMERIC);
DefaultValue.u64 = Default;
- Status = CreateDefaultOpCode (&DefaultValue, (NumericFlags & EFI_IFR_NUMERIC_SIZE), Data);
+ Status = CreateDefaultOpCode (&DefaultValue, (UINT8)(NumericFlags & EFI_IFR_NUMERIC_SIZE), Data);
if (EFI_ERROR(Status)) {
return Status;
}
|