diff --git a/BootloaderCommonPkg/Library/BootloaderDebugLib/DebugLib.c b/BootloaderCommonPkg/Library/BootloaderDebugLib/DebugLib.c index 74513137..837c4b58 100644 --- a/BootloaderCommonPkg/Library/BootloaderDebugLib/DebugLib.c +++ b/BootloaderCommonPkg/Library/BootloaderDebugLib/DebugLib.c @@ -63,8 +63,6 @@ DebugPrint ( return; } - Length = AsciiStrLen (Buffer); - // // Convert the DEBUG() message to an ASCII String // @@ -72,6 +70,8 @@ DebugPrint ( AsciiVSPrint (Buffer, sizeof (Buffer), Format, Marker); VA_END (Marker); + Length = AsciiStrLen (Buffer); + // // Send the print string to debug output handler //