diff options
Diffstat (limited to 'NetworkPkg/Ip4Dxe/Ip4If.c')
-rw-r--r-- | NetworkPkg/Ip4Dxe/Ip4If.c | 6 |
1 files changed, 5 insertions, 1 deletions
diff --git a/NetworkPkg/Ip4Dxe/Ip4If.c b/NetworkPkg/Ip4Dxe/Ip4If.c index 53a333037f..348f2e076a 100644 --- a/NetworkPkg/Ip4Dxe/Ip4If.c +++ b/NetworkPkg/Ip4Dxe/Ip4If.c @@ -491,9 +491,13 @@ Ip4CreateInterface ( IP4_INTERFACE *Interface;
EFI_SIMPLE_NETWORK_MODE SnpMode;
+ if (Mnp == NULL) {
+ return NULL;
+ }
+
Interface = AllocatePool (sizeof (IP4_INTERFACE));
- if ((Interface == NULL) || (Mnp == NULL)) {
+ if (Interface == NULL) {
return NULL;
}
|