MdeModulePkg RamDiskDxe: Fix VS2010 build error

Potentially uninitialized local variables 'TableKey' and 'TableHeader'
might be used in functions RamDiskPublishNfit() and RamDiskUnpublishNfit()
in file RamDiskProtocol.c.

Contributed-under: TianoCore Contribution Agreement 1.0
Signed-off-by: Hao Wu <hao.a.wu@intel.com>
Reviewed-by: Qiu Shumin <shumin.qiu@intel.com>
This commit is contained in:
Hao Wu 2016-05-27 12:42:36 +08:00
parent 265fff3948
commit 3ab7066e8d
1 changed files with 8 additions and 4 deletions

View File

@ -203,6 +203,8 @@ RamDiskPublishNfit (
//
Status = EFI_SUCCESS;
TableIndex = 0;
TableKey = 0;
TableHeader = NULL;
while (!EFI_ERROR (Status)) {
Status = mAcpiSdtProtocol->GetAcpiTable (
@ -388,6 +390,8 @@ RamDiskUnpublishNfit (
//
Status = EFI_SUCCESS;
TableIndex = 0;
TableKey = 0;
TableHeader = NULL;
while (!EFI_ERROR (Status)) {
Status = mAcpiSdtProtocol->GetAcpiTable (