diff options
author | Ye Ting <ting.ye@intel.com> | 2014-09-24 09:35:32 +0000 |
---|---|---|
committer | tye1 <tye1@6f19259b-4bc3-4df7-8a09-765794883524> | 2014-09-24 09:35:32 +0000 |
commit | d28c4ed72bb390b1152c114b0b34374428956871 (patch) | |
tree | f0205a191b3693715581f89db81b336a641312be /MdeModulePkg/Universal | |
parent | f55d71ec95660eefd9bf7a5ef54534e80e42e71b (diff) | |
download | edk2-platforms-d28c4ed72bb390b1152c114b0b34374428956871.tar.xz |
Enhance TargetName check when save iSCSI configuration.
Contributed-under: TianoCore Contribution Agreement 1.0
Signed-off-by: Ye Ting <ting.ye@intel.com>
Reviewed-by: Wu, Jiaxin <jiaxin.wu@intel.com>
Reviewed-by: Fu, Siyuan <siyuan.fu@intel.com>
git-svn-id: https://svn.code.sf.net/p/edk2/code/trunk/edk2@16167 6f19259b-4bc3-4df7-8a09-765794883524
Diffstat (limited to 'MdeModulePkg/Universal')
-rw-r--r-- | MdeModulePkg/Universal/Network/IScsiDxe/IScsiConfig.c | 17 |
1 files changed, 17 insertions, 0 deletions
diff --git a/MdeModulePkg/Universal/Network/IScsiDxe/IScsiConfig.c b/MdeModulePkg/Universal/Network/IScsiDxe/IScsiConfig.c index f8ae161b4c..e263f0e306 100644 --- a/MdeModulePkg/Universal/Network/IScsiDxe/IScsiConfig.c +++ b/MdeModulePkg/Universal/Network/IScsiDxe/IScsiConfig.c @@ -872,6 +872,23 @@ IScsiFormCallback ( Status = EFI_INVALID_PARAMETER;
break;
}
+
+ //
+ // Validate iSCSI target name configuration again:
+ // The format of iSCSI target name is already verified when user input the name;
+ // here we only check the case user does not input the name.
+ //
+ if (Private->Current->SessionConfigData.TargetName[0] == '\0') {
+ CreatePopUp (
+ EFI_LIGHTGRAY | EFI_BACKGROUND_BLUE,
+ &Key,
+ L"iSCSI target name is NULL!",
+ NULL
+ );
+ Status = EFI_INVALID_PARAMETER;
+ break;
+ }
+
}
if (IfrNvData->CHAPType != ISCSI_CHAP_NONE) {
|