summaryrefslogtreecommitdiffstats
path: root/src/hci/strerror.c
diff options
context:
space:
mode:
authorMichael Brown2008-04-08 17:28:00 +0200
committerMichael Brown2008-04-08 17:28:00 +0200
commit3475b693b7fdc7a21902648f01e2dea2b64fec39 (patch)
treeb46eb08b67f2aff2fff29708a005073ade388398 /src/hci/strerror.c
parent[Drivers-r8169] Add support for newer rtl8169 variants from Hilko Bengen (diff)
downloadipxe-3475b693b7fdc7a21902648f01e2dea2b64fec39.tar.gz
ipxe-3475b693b7fdc7a21902648f01e2dea2b64fec39.tar.xz
ipxe-3475b693b7fdc7a21902648f01e2dea2b64fec39.zip
[HCI] Display "Not an executable image" when appropriate
PXE is a catch-all image format with no signature checks. If an unsupported image file is loaded, it will be treated as a PXE image. In most cases, the image will be too large to be loaded as a PXE image (which has to fit in base memory), so the error returned to the user will be that the segment could not fit within the memory region. Add an explicit check to pxe_image.c to reject images larger than base memory with ENOEXEC. Add ENOEXEC to the error string table.
Diffstat (limited to 'src/hci/strerror.c')
-rw-r--r--src/hci/strerror.c1
1 files changed, 1 insertions, 0 deletions
diff --git a/src/hci/strerror.c b/src/hci/strerror.c
index 4fc15d01..69675905 100644
--- a/src/hci/strerror.c
+++ b/src/hci/strerror.c
@@ -118,4 +118,5 @@ struct errortab common_errors[] __errortab = {
{ ETIMEDOUT, "Connection timed out" },
{ EPIPE, "Broken pipe" },
{ ECANCELED, "Operation cancelled" },
+ { ENOEXEC, "Not an executable image" },
};