Fixes the GCC build 'Unused variable' warning (raised an error when warnings are treated as errors).

Contributed-under: TianoCore Contribution Agreement 1.0
Signed-off-by: Olivier Martin <olivier.martin@arm.com>
Reviewed-by: Eric Dong <eric.dong@intel.com>

git-svn-id: https://svn.code.sf.net/p/edk2/code/trunk/edk2@14470 6f19259b-4bc3-4df7-8a09-765794883524
This commit is contained in:
Olivier Martin 2013-07-16 02:11:24 +00:00 committed by ydong10
parent f5f89bf77d
commit 270e8dfd86
2 changed files with 48 additions and 64 deletions

View File

@ -1001,7 +1001,6 @@ ValidateQuestionFromVfr (
)
{
IFR_BLOCK_DATA VarBlockData;
UINT8 *TmpBuffer;
UINT16 Offset;
UINT16 Width;
UINT64 VarValue;
@ -1032,7 +1031,6 @@ ValidateQuestionFromVfr (
Index = 0;
VarStoreName = NULL;
Status = EFI_SUCCESS;
TmpBuffer = NULL;
VarValue = 0;
IfrVarStore = NULL;
IfrNameValueStore = NULL;
@ -1586,16 +1584,12 @@ GetBlockDataInfo (
LIST_ENTRY *Link;
UINTN MaxBufferSize;
EFI_STATUS Status;
CHAR8 *VarStoreName;
UINTN Index;
IFR_BLOCK_DATA *BlockArray;
UINT8 *DataBuffer;
//
// Initialize the local variables.
//
Index = 0;
VarStoreName = NULL;
Status = EFI_SUCCESS;
BlockData = NULL;
NewBlockData = NULL;

View File

@ -1433,20 +1433,12 @@ ParseIfrData (
CHAR16 *VarStoreName;
UINT16 VarWidth;
UINT16 VarDefaultId;
EFI_STRING GuidStr;
EFI_STRING NameStr;
EFI_STRING TempStr;
UINTN LengthString;
BOOLEAN FirstOneOfOption;
LIST_ENTRY *LinkData;
LIST_ENTRY *LinkDefault;
EFI_IFR_VARSTORE_NAME_VALUE *IfrNameValueVarStore;
LengthString = 0;
Status = EFI_SUCCESS;
GuidStr = NULL;
NameStr = NULL;
TempStr = NULL;
BlockData = NULL;
DefaultDataPtr = NULL;
FirstOneOfOption = FALSE;
@ -2875,7 +2867,6 @@ GetFullStringFromHiiFormPackages (
EFI_STRING ConfigHdr;
EFI_STRING StringPtr;
EFI_STRING Progress;
BOOLEAN DataExist;
if (DataBaseRecord == NULL || DevicePath == NULL || Request == NULL || AltCfgResp == NULL) {
return EFI_INVALID_PARAMETER;
@ -2891,7 +2882,6 @@ GetFullStringFromHiiFormPackages (
ConfigHdr = NULL;
HiiFormPackage = NULL;
PackageSize = 0;
DataExist = FALSE;
Progress = *Request;
Status = GetFormPackageData (DataBaseRecord, &HiiFormPackage, &PackageSize);