httpboot: fix the infinite loop

We should get out of the loop once the uri node is not the last node in
the device path.

Signed-off-by: Gary Lin <glin@suse.com>
This commit is contained in:
Gary Lin 2018-01-05 16:51:39 +08:00 committed by Peter Jones
parent a752290c38
commit 736af67122

View File

@ -162,7 +162,7 @@ find_httpboot (EFI_HANDLE device)
/* to download the second stage loader in that case. */
NextNode = NextDevicePathNode(Node);
if (!IsDevicePathEnd(NextNode))
continue;
goto out;
/* Save the current URI */
UriNode = (URI_DEVICE_PATH *)Node;