\r
Status = EFI_SUCCESS;\r
ActionRequest = EFI_BROWSER_ACTION_REQUEST_NONE;\r
- \r
- if ((Statement->QuestionFlags & EFI_IFR_FLAG_CALLBACK) != EFI_IFR_FLAG_CALLBACK) {\r
+\r
+ if (((Statement->QuestionFlags & EFI_IFR_FLAG_CALLBACK) != EFI_IFR_FLAG_CALLBACK) || ConfigAccess == NULL) {\r
return EFI_UNSUPPORTED;\r
}\r
\r
// for each question with callback flag.\r
// New form may be the first form, or the different form after another form close.\r
//\r
- if ((ConfigAccess != NULL) &&\r
- ((Selection->Handle != mCurrentHiiHandle) ||\r
+ if (((Selection->Handle != mCurrentHiiHandle) ||\r
(!CompareGuid (&Selection->FormSetGuid, &mCurrentFormSetGuid)) ||\r
(Selection->FormId != mCurrentFormId))) {\r
//\r
CopyGuid (&mCurrentFormSetGuid, &Selection->FormSetGuid);\r
mCurrentFormId = Selection->FormId;\r
\r
- Status = ProcessCallBackFunction (Selection, gCurrentSelection->FormSet, Selection->Form, NULL, EFI_BROWSER_ACTION_FORM_OPEN, FALSE);\r
- if (EFI_ERROR (Status)) {\r
- goto Done;\r
- }\r
+ if (ConfigAccess != NULL) {\r
+ Status = ProcessCallBackFunction (Selection, gCurrentSelection->FormSet, Selection->Form, NULL, EFI_BROWSER_ACTION_FORM_OPEN, FALSE);\r
+ if (EFI_ERROR (Status)) {\r
+ goto Done;\r
+ }\r
\r
- //\r
- // IFR is updated during callback of open form, force to reparse the IFR binary\r
- //\r
- if (mHiiPackageListUpdated) {\r
- Selection->Action = UI_ACTION_REFRESH_FORMSET;\r
- mHiiPackageListUpdated = FALSE;\r
- break;\r
+ //\r
+ // IFR is updated during callback of open form, force to reparse the IFR binary\r
+ //\r
+ if (mHiiPackageListUpdated) {\r
+ Selection->Action = UI_ACTION_REFRESH_FORMSET;\r
+ mHiiPackageListUpdated = FALSE;\r
+ break;\r
+ }\r
}\r
}\r
\r