mirror of https://github.com/acidanthera/audk.git
NetworkPkg/IScsiDxe: Add check to avoid use NULL pointer
Cc: Wu Hao A <hao.a.wu@intel.com> Cc: Ye Ting <ting.ye@intel.com> Cc: Fu Siyuan <siyuan.fu@intel.com> Contributed-under: TianoCore Contribution Agreement 1.0 Signed-off-by: Wu Jiaxin <jiaxin.wu@intel.com> Reviewed-by: Hao Wu <hao.a.wu@intel.com>
This commit is contained in:
parent
770f9aae09
commit
0e7794d36d
|
@ -3596,6 +3596,10 @@ IScsiFormCallback (
|
|||
switch (Value->u8) {
|
||||
case IP_MODE_IP6:
|
||||
NicInfo = IScsiGetNicInfoByIndex (Private->Current->NicIndex);
|
||||
if(NicInfo == NULL) {
|
||||
break;
|
||||
}
|
||||
|
||||
if(!NicInfo->Ipv6Available) {
|
||||
//
|
||||
// Current NIC doesn't Support IPv6, hence use IPv4.
|
||||
|
|
Loading…
Reference in New Issue