mirror of
https://github.com/tianocore/edk2
synced 2026-08-27 00:23:19 -04:00
MdeModulePkg/PeiDxeDebugLibReportStatusCode: Fix comma parsing
The DebugPrintMarker function in PeiDxeDebugLibReportStatusCode/DebugLib.c does not recognize the comma (`,`) flag in printf-style format strings. When a driver uses format strings with thousand separators like "%,ld" to format large numbers (e.g., 1234567 as "1,234,567"), the DebugPrintMarker parser fails to recognize the comma flag and causes incorrect argument extraction when building the BASE_LIST for status code reporting, leading to unexpected or corrupted debug output in status code reports. The change is to add the missing comma flag check to align with BasePrintLib's format parsing logic, ensuring consistent behavior across all print library implementations. Signed-off-by: Ray Ni <ray.ni@intel.com>
This commit is contained in:
parent
a7c119589f
commit
4d0946c082
1 changed files with 1 additions and 1 deletions
|
|
@ -181,7 +181,7 @@ DebugPrintMarker (
|
|||
// Parse Flags and Width
|
||||
//
|
||||
for (Format++; TRUE; Format++) {
|
||||
if ((*Format == '.') || (*Format == '-') || (*Format == '+') || (*Format == ' ')) {
|
||||
if ((*Format == '.') || (*Format == '-') || (*Format == '+') || (*Format == ' ') || (*Format == ',')) {
|
||||
//
|
||||
// These characters in format field are omitted.
|
||||
//
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue