loader: Print autoboot countdown immediately, not at 9
For the first second otime and ntime are equal so no message gets printed. Instead we should print the countdown right from the start, although we do it at the end of the first iteration so that if a key has already been pressed then the message is suppressed. Reviewed by: imp Approved by: imp Differential Revision: https://reviews.freebsd.org/D26935
This commit is contained in:
parent
a8001da710
commit
d11c1cf1b1
@ -202,8 +202,9 @@ autoboot(int timeout, char *prompt)
|
||||
}
|
||||
|
||||
if (timeout >= 0) {
|
||||
otime = time(NULL);
|
||||
when = otime + timeout; /* when to boot */
|
||||
otime = -1;
|
||||
ntime = time(NULL);
|
||||
when = ntime + timeout; /* when to boot */
|
||||
|
||||
yes = 0;
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user