tty-register(): Fix regression in built-in TTY baud + term parser

Signed-off-by: Joachim Nilsson <troglobit@gmail.com>
This commit is contained in:
Joachim Nilsson
2017-09-01 06:40:52 +02:00
parent 529b39ebba
commit b8a7cb6b93
+3 -3
View File
@@ -115,7 +115,7 @@ void tty_sweep(void)
* a leading '/dev' is encountered the remaining options must be in
* the following sequence:
*
* tty [!1-9,S] <DEV> [BAUD[,BAUD,...]] [TERM] [noclear] [nowait]
* tty [!1-9,S] <DEV> [BAUD[,BAUD,...]] [noclear] [nowait] [TERM]
*
* Otherwise the leading prefix must be the full path to an existing
* getty implementation, with it's arguments following:
@@ -176,7 +176,7 @@ int tty_register(char *line, struct timeval *mtime)
/* Built-in getty args */
if (dev) {
if (isdigit(args[i][0])) {
baud = tok;
baud = args[i];
continue;
}
@@ -185,7 +185,7 @@ int tty_register(char *line, struct timeval *mtime)
* to be used for the TERM environment variable.
*/
if (i + 1 == num)
term = tok;
term = args[i];
}
/* External getty, figure out the device */