david/ipxe
Archived
1
0

[autoboot] Use a custom error number for "nothing to boot"

Signed-off-by: Michael Brown <mcb30@ipxe.org>
This commit is contained in:
Michael Brown 2011-02-28 18:43:54 +00:00
parent 7617e36f9e
commit e583afb977

View File

@ -41,6 +41,11 @@ FILE_LICENCE ( GPL2_OR_LATER );
* *
*/ */
/* Disambiguate the various error causes */
#define ENOENT_BOOT __einfo_error ( EINFO_ENOENT_BOOT )
#define EINFO_ENOENT_BOOT \
__einfo_uniqify ( EINFO_ENOENT, 0x01, "Nothing to boot" )
/** /**
* Perform PXE menu boot when PXE stack is not available * Perform PXE menu boot when PXE stack is not available
*/ */
@ -185,7 +190,7 @@ int uriboot ( struct uri *filename, struct uri *root_path ) {
rc = 0; rc = 0;
} }
} else { } else {
rc = -ENOENT; rc = -ENOENT_BOOT;
printf ( "Nothing to boot: %s\n", strerror ( rc ) ); printf ( "Nothing to boot: %s\n", strerror ( rc ) );
} }