StandaloneMmPkg: Fix ECC error 5007 in StandaloneMmCore

Bugzilla: 3150 (https://bugzilla.tianocore.org/show_bug.cgi?id=3150)

Fix ECC error "[5007] There should be no initialization of a variable
as part of its declaration Variable."

Signed-off-by: Sami Mujawar <sami.mujawar@arm.com>
Acked-by: Jiewen Yao <Jiewen.yao@intel.com>
Acked-by: Ard Biesheuvel <ard.biesheuvel@arm.com>
Reviewed-by: Liming Gao <gaoliming@byosoft.com.cn>
This commit is contained in:
Sami Mujawar 2020-12-03 20:52:01 +00:00 committed by mergify[bot]
parent eda1ffacf1
commit eff8f7a9b4
1 changed files with 4 additions and 2 deletions

View File

@ -149,9 +149,10 @@ MmExitBootServiceHandler (
)
{
EFI_HANDLE MmHandle;
EFI_STATUS Status = EFI_SUCCESS;
EFI_STATUS Status;
STATIC BOOLEAN mInExitBootServices = FALSE;
Status = EFI_SUCCESS;
if (!mInExitBootServices) {
MmHandle = NULL;
Status = MmInstallProtocolInterface (
@ -187,9 +188,10 @@ MmReadyToBootHandler (
)
{
EFI_HANDLE MmHandle;
EFI_STATUS Status = EFI_SUCCESS;
EFI_STATUS Status;
STATIC BOOLEAN mInReadyToBoot = FALSE;
Status = EFI_SUCCESS;
if (!mInReadyToBoot) {
MmHandle = NULL;
Status = MmInstallProtocolInterface (