MdeModulePkg/Universal/HiiDatabaseDxe/Database.c | 3 +++ 1 file changed, 3 insertions(+)
Make VS2012x86 and GCC48 pass build
Contributed-under: TianoCore Contribution Agreement 1.1
Signed-off-by: Liming Gao <liming.gao@intel.com>
---
MdeModulePkg/Universal/HiiDatabaseDxe/Database.c | 3 +++
1 file changed, 3 insertions(+)
diff --git a/MdeModulePkg/Universal/HiiDatabaseDxe/Database.c b/MdeModulePkg/Universal/HiiDatabaseDxe/Database.c
index ffcd9ec..7441c19 100644
--- a/MdeModulePkg/Universal/HiiDatabaseDxe/Database.c
+++ b/MdeModulePkg/Universal/HiiDatabaseDxe/Database.c
@@ -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;
--
2.8.0.windows.1
_______________________________________________
edk2-devel mailing list
edk2-devel@lists.01.org
https://lists.01.org/mailman/listinfo/edk2-devel
Reviewed-by: Eric Dong <eric.dong@intel.com> -----Original Message----- From: edk2-devel [mailto:edk2-devel-bounces@lists.01.org] On Behalf Of Liming Gao Sent: Monday, December 25, 2017 6:25 PM To: edk2-devel@lists.01.org Subject: [edk2] [Patch] 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> --- MdeModulePkg/Universal/HiiDatabaseDxe/Database.c | 3 +++ 1 file changed, 3 insertions(+) diff --git a/MdeModulePkg/Universal/HiiDatabaseDxe/Database.c b/MdeModulePkg/Universal/HiiDatabaseDxe/Database.c index ffcd9ec..7441c19 100644 --- a/MdeModulePkg/Universal/HiiDatabaseDxe/Database.c +++ b/MdeModulePkg/Universal/HiiDatabaseDxe/Database.c @@ -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; -- 2.8.0.windows.1 _______________________________________________ edk2-devel mailing list edk2-devel@lists.01.org https://lists.01.org/mailman/listinfo/edk2-devel _______________________________________________ edk2-devel mailing list edk2-devel@lists.01.org https://lists.01.org/mailman/listinfo/edk2-devel
© 2016 - 2024 Red Hat, Inc.