From cae974bea25a3193360390af0b405488a19e1e15 Mon Sep 17 00:00:00 2001 From: Tomas Pilar Date: Fri, 19 Jun 2020 12:59:54 +0100 Subject: ShellPkg/AcpiView: Move log reset to main method The error and warning counters are reset in the AcpiView main method. This improves reusability of the main method. Cc: Ray Ni Cc: Zhichao Gao Reviewed-by: Zhichao Gao Signed-off-by: Tomas Pilar --- ShellPkg/Library/UefiShellAcpiViewCommandLib/AcpiView.c | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) (limited to 'ShellPkg') diff --git a/ShellPkg/Library/UefiShellAcpiViewCommandLib/AcpiView.c b/ShellPkg/Library/UefiShellAcpiViewCommandLib/AcpiView.c index 84ffb35957..f1a95b7b8f 100644 --- a/ShellPkg/Library/UefiShellAcpiViewCommandLib/AcpiView.c +++ b/ShellPkg/Library/UefiShellAcpiViewCommandLib/AcpiView.c @@ -424,6 +424,10 @@ AcpiView ( EfiConfigurationTable = NULL; OriginalAttribute = 0; + // Reset The error/warning counters + ResetErrorCount (); + ResetWarningCount (); + // Search the table for an entry that matches the ACPI Table Guid FoundAcpiTable = FALSE; for (Index = 0; Index < SystemTable->NumberOfTableEntries; Index++) { @@ -566,10 +570,6 @@ ShellCommandRunAcpiView ( Package = NULL; TmpDumpFileHandle = NULL; - // Reset The error/warning counters - ResetErrorCount (); - ResetWarningCount (); - Status = ShellCommandLineParse (ParamList, &Package, &ProblemParam, TRUE); if (EFI_ERROR (Status)) { if (Status == EFI_VOLUME_CORRUPTED && ProblemParam != NULL) { -- cgit v1.2.3