summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--SourceLevelDebugPkg/Library/DebugAgent/SecPeiDebugAgent/SecPeiDebugAgentLib.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/SourceLevelDebugPkg/Library/DebugAgent/SecPeiDebugAgent/SecPeiDebugAgentLib.c b/SourceLevelDebugPkg/Library/DebugAgent/SecPeiDebugAgent/SecPeiDebugAgentLib.c
index a3f91d3358..7a7ca423c7 100644
--- a/SourceLevelDebugPkg/Library/DebugAgent/SecPeiDebugAgent/SecPeiDebugAgentLib.c
+++ b/SourceLevelDebugPkg/Library/DebugAgent/SecPeiDebugAgent/SecPeiDebugAgentLib.c
@@ -613,7 +613,7 @@ InitializeDebugAgent (
//
// Set return status for DEBUG_AGENT_INIT_PEI
//
- if (InitFlag == DEBUG_AGENT_INIT_PEI) {
+ if (InitFlag == DEBUG_AGENT_INIT_PEI && Context != NULL) {
*(EFI_STATUS *)Context = EFI_SUCCESS;
}
}