From b3efbda1660372f3973c29cde0e92528862c4171 Mon Sep 17 00:00:00 2001 From: Leandro Becker Date: Fri, 20 Sep 2024 10:37:57 -0300 Subject: NetworkPkg/HttpBootDxe: Report download error when resume attempts fail When all resume attempts to continue an interrupted NBP file download have failed, report the failure status to the caller. Original implementation was returning success when number of retries reaches the limit defined by PcdMaxHttpResumeRetries. Signed-off-by: Leandro Gustavo Biss Becker --- NetworkPkg/HttpBootDxe/HttpBootImpl.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) (limited to 'NetworkPkg') diff --git a/NetworkPkg/HttpBootDxe/HttpBootImpl.c b/NetworkPkg/HttpBootDxe/HttpBootImpl.c index 6f10bcff39..91e934ce06 100644 --- a/NetworkPkg/HttpBootDxe/HttpBootImpl.c +++ b/NetworkPkg/HttpBootDxe/HttpBootImpl.c @@ -388,7 +388,8 @@ HttpBootGetBootFileCaller ( ImageType ); if (!EFI_ERROR (Status) || - ((Status != EFI_TIMEOUT) && (Status != EFI_DEVICE_ERROR))) + ((Status != EFI_TIMEOUT) && (Status != EFI_DEVICE_ERROR)) || + (Retries >= PcdGet32 (PcdMaxHttpResumeRetries))) { break; } -- cgit v1.2.3