summaryrefslogtreecommitdiffstats
path: root/src/usr
diff options
context:
space:
mode:
authorMichael Brown2011-03-02 20:39:39 +0100
committerMichael Brown2011-03-02 20:39:39 +0100
commit8a61e37e2e75df46714e02b6cfb3a7838d9d41e3 (patch)
treed010c9921b0537b3c3a5f7bfa8d0cbec8472c92d /src/usr
parent[image] Allow download job to complete before acting upon image (diff)
downloadipxe-8a61e37e2e75df46714e02b6cfb3a7838d9d41e3.tar.gz
ipxe-8a61e37e2e75df46714e02b6cfb3a7838d9d41e3.tar.xz
ipxe-8a61e37e2e75df46714e02b6cfb3a7838d9d41e3.zip
[autoboot] Tidy up output following NBP execution
If the NBP returns, then always print a trailing newline, since some NBPs (e.g. wdsnbp.com) leave the cursor in a random position halfway across the screen. Signed-off-by: Michael Brown <mcb30@ipxe.org>
Diffstat (limited to 'src/usr')
-rw-r--r--src/usr/autoboot.c8
1 files changed, 7 insertions, 1 deletions
diff --git a/src/usr/autoboot.c b/src/usr/autoboot.c
index 0fe00b36..c743404c 100644
--- a/src/usr/autoboot.c
+++ b/src/usr/autoboot.c
@@ -175,8 +175,14 @@ int uriboot ( struct uri *filename, struct uri *root_path ) {
if ( filename ) {
if ( ( rc = imgdownload ( image, filename,
register_and_autoexec_image ) ) !=0){
- printf ( "Could not chain image: %s\n",
+ printf ( "\nCould not chain image: %s\n",
strerror ( rc ) );
+ } else {
+ /* Always print an extra newline, because we
+ * don't know where the NBP may have left the
+ * cursor.
+ */
+ printf ( "\n" );
}
} else if ( root_path ) {
if ( fetch_intz_setting ( NULL, &skip_san_boot_setting) == 0 ) {