summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--EdkUnixPkg/Dxe/PlatformBds/Generic/BootMaint/BootMaint.c3
1 files changed, 3 insertions, 0 deletions
diff --git a/EdkUnixPkg/Dxe/PlatformBds/Generic/BootMaint/BootMaint.c b/EdkUnixPkg/Dxe/PlatformBds/Generic/BootMaint/BootMaint.c
index 9b84db59d0..69da6768e9 100644
--- a/EdkUnixPkg/Dxe/PlatformBds/Generic/BootMaint/BootMaint.c
+++ b/EdkUnixPkg/Dxe/PlatformBds/Generic/BootMaint/BootMaint.c
@@ -449,6 +449,7 @@ Returns:
Index2 = (UINT16) (KeyValue - HANDLE_OPTION_OFFSET);
NewMenuEntry = BOpt_GetMenuEntry (&DriverMenu, Index2);
+ ASSERT (NewMenuEntry != NULL);
Private->HandleContext = (BM_HANDLE_CONTEXT *) NewMenuEntry->VariableContext;
CleanUpPage (FORM_DRV_ADD_HANDLE_DESC_ID, Private);
@@ -556,6 +557,8 @@ Returns:
case FORM_CON_COM_ID:
NewMenuEntry = BOpt_GetMenuEntry (&TerminalMenu, Private->CurrentTerminal);
+ ASSERT (NewMenuEntry != NULL);
+
NewTerminalContext = (BM_TERMINAL_CONTEXT *) NewMenuEntry->VariableContext;
NewTerminalContext->BaudRateIndex = CurrentFakeNVMap->COMBaudRate;