From: Michael D Kinney Date: Sun, 5 Dec 2021 22:33:41 +0000 (-0800) Subject: ArmVirtPkg: Change complex DEBUG_CODE() to DEBUG_CODE_BEGIN/END() X-Git-Tag: edk2-stable202202~243 X-Git-Url: https://git.proxmox.com/?p=mirror_edk2.git;a=commitdiff_plain;h=ea85f0fe1313a0090f4fa287bb75dbf3a00e0909 ArmVirtPkg: Change complex DEBUG_CODE() to DEBUG_CODE_BEGIN/END() REF: https://bugzilla.tianocore.org/show_bug.cgi?id=3767 Update use of DEBUG_CODE(Expression) if Expression is a complex code block with if/while/for/case statements that use {}. Cc: Andrew Fish Cc: Leif Lindholm Cc: Michael Kubacki Signed-off-by: Michael D Kinney Reviewed-by: Sami Mujawar --- diff --git a/ArmVirtPkg/Library/PlatformBootManagerLib/PlatformBm.c b/ArmVirtPkg/Library/PlatformBootManagerLib/PlatformBm.c index bb3140f2d6..02d6c87050 100644 --- a/ArmVirtPkg/Library/PlatformBootManagerLib/PlatformBm.c +++ b/ArmVirtPkg/Library/PlatformBootManagerLib/PlatformBm.c @@ -605,7 +605,7 @@ RemoveStaleFvFileOptions ( // Status = EfiBootManagerDeleteLoadOptionVariable ( BootOptions[Index].OptionNumber, LoadOptionTypeBoot); - DEBUG_CODE ( + DEBUG_CODE_BEGIN (); CHAR16 *DevicePathString; DevicePathString = ConvertDevicePathToText(BootOptions[Index].FilePath, @@ -621,7 +621,7 @@ RemoveStaleFvFileOptions ( if (DevicePathString != NULL) { FreePool (DevicePathString); } - ); + DEBUG_CODE_END (); } EfiBootManagerFreeLoadOptions (BootOptions, BootOptionCount);