diff --git a/NetworkPkg/HttpBootDxe/HttpBootConfig.c b/NetworkPkg/HttpBootDxe/HttpBootConfig.c index 2ca38b5333..04c2f3efd7 100644 --- a/NetworkPkg/HttpBootDxe/HttpBootConfig.c +++ b/NetworkPkg/HttpBootDxe/HttpBootConfig.c @@ -142,9 +142,7 @@ HttpBootAddBootOption ( } Status = EfiBootManagerAddLoadOptionVariable (&NewOption, (UINTN) -1); - if (EFI_ERROR (Status)) { - EfiBootManagerFreeLoadOption (&NewOption); - } + EfiBootManagerFreeLoadOption (&NewOption); ON_EXIT: