From 68bef3f0c7c71da2f065fd348efa79f04799d347 Mon Sep 17 00:00:00 2001 From: AlexeiFedorov Date: Fri, 13 Jul 2018 23:17:01 +0800 Subject: [PATCH] ShellPkg/UefiShellAcpiViewCommandLib: Fix VS2017 compilation errors This patch fixes VS2017 compilation errors for UefiShellAcpiViewCommandLib\Parsers\Gtdt\GtdtParser.c and UefiShellAcpiViewCommandLib\Parsers\Xsdt\XsdtParser.c reported in https://bugzilla.tianocore.org/show_bug.cgi?id=985 https://bugzilla.tianocore.org/show_bug.cgi?id=986 Contributed-under: TianoCore Contribution Agreement 1.1 Signed-off-by: Alexei Fedorov Reviewed-by: Jaben Carsey --- .../Parsers/Gtdt/GtdtParser.c | 4 ++-- .../Parsers/Xsdt/XsdtParser.c | 12 ++++++------ 2 files changed, 8 insertions(+), 8 deletions(-) diff --git a/ShellPkg/Library/UefiShellAcpiViewCommandLib/Parsers/Gtdt/GtdtParser.c b/ShellPkg/Library/UefiShellAcpiViewCommandLib/Parsers/Gtdt/GtdtParser.c index 3a3cee948a..0ab460b02c 100644 --- a/ShellPkg/Library/UefiShellAcpiViewCommandLib/Parsers/Gtdt/GtdtParser.c +++ b/ShellPkg/Library/UefiShellAcpiViewCommandLib/Parsers/Gtdt/GtdtParser.c @@ -161,12 +161,12 @@ STATIC VOID DumpGTBlock ( IN UINT8* Ptr, - IN UINT16 Length + IN UINT32 Length ) { UINT32 Index; UINT32 Offset; - UINT16 GTBlockTimerLength; + UINT32 GTBlockTimerLength; Offset = ParseAcpi ( TRUE, diff --git a/ShellPkg/Library/UefiShellAcpiViewCommandLib/Parsers/Xsdt/XsdtParser.c b/ShellPkg/Library/UefiShellAcpiViewCommandLib/Parsers/Xsdt/XsdtParser.c index 99521cd67a..a5e1412484 100644 --- a/ShellPkg/Library/UefiShellAcpiViewCommandLib/Parsers/Xsdt/XsdtParser.c +++ b/ShellPkg/Library/UefiShellAcpiViewCommandLib/Parsers/Xsdt/XsdtParser.c @@ -96,7 +96,7 @@ ParseAcpiXsdt ( CONST UINT8* Revision; if ((UINT64*)(UINTN)(*TablePointer) != NULL) { - UINT8* Ptr; + UINT8* SignaturePtr; ParseAcpiHeader ( (UINT8*)(UINTN)(*TablePointer), @@ -105,17 +105,17 @@ ParseAcpiXsdt ( &Revision ); - Ptr = (UINT8*)Signature; + SignaturePtr = (UINT8*)Signature; UnicodeSPrint ( Buffer, sizeof (Buffer), L"Entry[%d] - %c%c%c%c", EntryIndex++, - Ptr[0], - Ptr[1], - Ptr[2], - Ptr[3] + SignaturePtr[0], + SignaturePtr[1], + SignaturePtr[2], + SignaturePtr[3] ); } else { UnicodeSPrint ( -- 2.39.2