Browse Source

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

Signed-off-by: Michael Brown <mcb30@ipxe.org>
tags/v1.20.1
Michael Brown 13 years ago
parent
commit
e583afb977
1 changed files with 6 additions and 1 deletions
  1. 6
    1
      src/usr/autoboot.c

+ 6
- 1
src/usr/autoboot.c View File

41
  *
41
  *
42
  */
42
  */
43
 
43
 
44
+/* Disambiguate the various error causes */
45
+#define ENOENT_BOOT __einfo_error ( EINFO_ENOENT_BOOT )
46
+#define EINFO_ENOENT_BOOT \
47
+	__einfo_uniqify ( EINFO_ENOENT, 0x01, "Nothing to boot" )
48
+
44
 /**
49
 /**
45
  * Perform PXE menu boot when PXE stack is not available
50
  * Perform PXE menu boot when PXE stack is not available
46
  */
51
  */
185
 			rc = 0;
190
 			rc = 0;
186
 		}
191
 		}
187
 	} else {
192
 	} else {
188
-		rc = -ENOENT;
193
+		rc = -ENOENT_BOOT;
189
 		printf ( "Nothing to boot: %s\n", strerror ( rc ) );
194
 		printf ( "Nothing to boot: %s\n", strerror ( rc ) );
190
 	}
195
 	}
191
 
196
 

Loading…
Cancel
Save