MdeModulePkg/Variable: Fix VS2015 warning about uninitialized local var.
authorMichael D Kinney <michael.d.kinney@intel.com>
Wed, 29 Jul 2015 11:11:34 +0000 (11:11 +0000)
committererictian <erictian@Edk2>
Wed, 29 Jul 2015 11:11:34 +0000 (11:11 +0000)
This fix is used to solve VS2015 warning "local variable is not initialized before use"

Contributed-under: TianoCore Contribution Agreement 1.0
Signed-off-by: Michael D Kinney <michael.d.kinney@intel.com>
Reviewed-by: Feng Tian <feng.tian@intel.com>
Reviewed-by: Star Zeng <star.zeng@intel.com>
git-svn-id: https://svn.code.sf.net/p/edk2/code/trunk/edk2@18108 6f19259b-4bc3-4df7-8a09-765794883524

MdeModulePkg/Universal/Variable/RuntimeDxe/Variable.c

index 3c99367..834d2ff 100644 (file)
@@ -4103,6 +4103,7 @@ VariableCommonInitialize (
   //\r
   // Init non-volatile variable store.\r
   //\r
+  NvFvHeader = NULL;\r
   Status = InitNonVolatileVariableStore (&NvFvHeader);\r
   if (EFI_ERROR (Status)) {\r
     FreePool (mVariableModuleGlobal);\r