summaryrefslogtreecommitdiff
path: root/IntelFrameworkModulePkg/Library/PeiReportStatusCodeLib/ReportStatusCodeLib.c
diff options
context:
space:
mode:
Diffstat (limited to 'IntelFrameworkModulePkg/Library/PeiReportStatusCodeLib/ReportStatusCodeLib.c')
-rw-r--r--IntelFrameworkModulePkg/Library/PeiReportStatusCodeLib/ReportStatusCodeLib.c4
1 files changed, 3 insertions, 1 deletions
diff --git a/IntelFrameworkModulePkg/Library/PeiReportStatusCodeLib/ReportStatusCodeLib.c b/IntelFrameworkModulePkg/Library/PeiReportStatusCodeLib/ReportStatusCodeLib.c
index d027dc4a8e..4f0901b1d2 100644
--- a/IntelFrameworkModulePkg/Library/PeiReportStatusCodeLib/ReportStatusCodeLib.c
+++ b/IntelFrameworkModulePkg/Library/PeiReportStatusCodeLib/ReportStatusCodeLib.c
@@ -471,7 +471,9 @@ ReportStatusCodeEx (
ExtendedDataGuid = &gEfiStatusCodeSpecificDataGuid;
}
CopyGuid (&StatusCodeData->Type, ExtendedDataGuid);
- CopyMem (StatusCodeData + 1, ExtendedData, ExtendedDataSize);
+ if (ExtendedData != NULL) {
+ CopyMem (StatusCodeData + 1, ExtendedData, ExtendedDataSize);
+ }
if (CallerId == NULL) {
CallerId = &gEfiCallerIdGuid;
}