summaryrefslogtreecommitdiff
path: root/MdeModulePkg/Universal/SetupBrowserDxe/Ui.c
diff options
context:
space:
mode:
Diffstat (limited to 'MdeModulePkg/Universal/SetupBrowserDxe/Ui.c')
-rw-r--r--MdeModulePkg/Universal/SetupBrowserDxe/Ui.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/MdeModulePkg/Universal/SetupBrowserDxe/Ui.c b/MdeModulePkg/Universal/SetupBrowserDxe/Ui.c
index db2bd27df3..5deb3019bc 100644
--- a/MdeModulePkg/Universal/SetupBrowserDxe/Ui.c
+++ b/MdeModulePkg/Universal/SetupBrowserDxe/Ui.c
@@ -2557,11 +2557,11 @@ UiDisplayMenu (
Selection->QuestionId = Statement->RefQuestionId;
} else if (Statement->RefFormId != 0) {
//
- // Check Ref From is suppressed.
+ // Check whether target From is suppressed.
//
RefForm = IdToForm (Selection->FormSet, Statement->RefFormId);
- if (RefForm->SuppressExpression != NULL) {
+ if ((RefForm != NULL) && (RefForm->SuppressExpression != NULL)) {
Status = EvaluateExpression (Selection->FormSet, RefForm, RefForm->SuppressExpression);
if (EFI_ERROR (Status)) {
return Status;