mirror of https://github.com/acidanthera/audk.git
NetworkPkg/IScsiDxe: Clean the previous ConfigData when switching the IP mode.
Cc: Karunakar P <karunakarp@amiindia.co.in> 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: Karunakar p <karunakarp@amiindia.co.in>
This commit is contained in:
parent
067ca83822
commit
b90741053d
|
@ -3592,8 +3592,15 @@ IScsiFormCallback (
|
|||
switch (Value->u8) {
|
||||
case IP_MODE_IP6:
|
||||
case IP_MODE_IP4:
|
||||
ZeroMem (IfrNvData->LocalIp, sizeof (IfrNvData->LocalIp));
|
||||
ZeroMem (IfrNvData->SubnetMask, sizeof (IfrNvData->SubnetMask));
|
||||
ZeroMem (IfrNvData->Gateway, sizeof (IfrNvData->Gateway));
|
||||
ZeroMem (IfrNvData->TargetIp, sizeof (IfrNvData->TargetIp));
|
||||
Private->Current->AutoConfigureMode = 0;
|
||||
ZeroMem (&Private->Current->SessionConfigData.LocalIp, sizeof (EFI_IP_ADDRESS));
|
||||
ZeroMem (&Private->Current->SessionConfigData.SubnetMask, sizeof (EFI_IPv4_ADDRESS));
|
||||
ZeroMem (&Private->Current->SessionConfigData.Gateway, sizeof (EFI_IP_ADDRESS));
|
||||
ZeroMem (&Private->Current->SessionConfigData.TargetIp, sizeof (EFI_IP_ADDRESS));
|
||||
|
||||
break;
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue