MdeModulePkg HiiDataBaseDxe: Initialize the local variable before reference

Make VS2012x86 and GCC48 pass build

Contributed-under: TianoCore Contribution Agreement 1.1
Signed-off-by: Liming Gao <liming.gao@intel.com>
Reviewed-by: Eric Dong <eric.dong@intel.com>
This commit is contained in:
Liming Gao 2017-12-25 18:24:19 +08:00
parent 7c73626513
commit 718b6fe9a3
1 changed files with 3 additions and 0 deletions

View File

@ -739,6 +739,8 @@ FindQuestionDefaultSetting (
if (VariableHeader == NULL) {
return EFI_NOT_FOUND;
}
StartBit = 0;
EndBit = 0;
ByteOffset = IfrQuestionHdr->VarStoreInfo.VarOffset;
if (BitFieldQuestion) {
BitOffset = IfrQuestionHdr->VarStoreInfo.VarOffset;
@ -818,6 +820,7 @@ UpdateDefaultSettingInFormPackage (
ZeroMem (&VarStoreQuestionHeader, sizeof (VarStoreQuestionHeader));
PackageLength = FormPackage->FormPkgHdr.Length - sizeof (EFI_HII_PACKAGE_HEADER);
Width = 0;
IfrOffset = 0;
IfrScope = 0;
IfrOpHdr = (EFI_IFR_OP_HEADER *) FormPackage->IfrData;