summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--MdeModulePkg/Universal/ReportStatusCodeRouter/Pei/ReportStatusCodeRouterPei.c2
1 files changed, 2 insertions, 0 deletions
diff --git a/MdeModulePkg/Universal/ReportStatusCodeRouter/Pei/ReportStatusCodeRouterPei.c b/MdeModulePkg/Universal/ReportStatusCodeRouter/Pei/ReportStatusCodeRouterPei.c
index e3ae334836..8a2dc8a9bd 100644
--- a/MdeModulePkg/Universal/ReportStatusCodeRouter/Pei/ReportStatusCodeRouterPei.c
+++ b/MdeModulePkg/Universal/ReportStatusCodeRouter/Pei/ReportStatusCodeRouterPei.c
@@ -249,6 +249,7 @@ ReportDispatcher (
NumberOfEntries = GET_GUID_HOB_DATA (Hob);
CallbackEntry = (EFI_PEI_RSC_HANDLER_CALLBACK *) (NumberOfEntries + 1);
for (Index = 0; Index < *NumberOfEntries; Index++) {
+ if (CallbackEntry[Index] != NULL) {
CallbackEntry[Index](
PeiServices,
CodeType,
@@ -257,6 +258,7 @@ ReportDispatcher (
CallerId,
Data
);
+ }
}
Hob.Raw = GET_NEXT_HOB (Hob);
Hob.Raw = GetNextGuidHob (&gStatusCodeCallbackGuid, Hob.Raw);