Reduce diffs with Peter's expanded diffs:
1) Put back the keyboard printing printf, at the cost of 58 bytes. 2) Minor tweak to getstr at no apparent cost.
This commit is contained in:
parent
9eebd265b9
commit
1c584b760c
Notes:
svn2git
2020-12-20 02:59:44 +00:00
svn path=/head/; revision=108005
@ -167,14 +167,14 @@ getstr(void)
|
||||
for (;;) {
|
||||
switch (c = xgetc(0)) {
|
||||
case 0:
|
||||
continue;
|
||||
break;
|
||||
case '\177':
|
||||
case '\b':
|
||||
if (s > cmd) {
|
||||
s--;
|
||||
printf("\b \b");
|
||||
}
|
||||
continue;
|
||||
break;
|
||||
case '\n':
|
||||
case '\r':
|
||||
*s = 0;
|
||||
@ -182,8 +182,8 @@ getstr(void)
|
||||
default:
|
||||
if (s - cmd < sizeof(cmd) - 1)
|
||||
*s++ = c;
|
||||
putchar(c);
|
||||
}
|
||||
putchar(c);
|
||||
}
|
||||
}
|
||||
|
||||
@ -388,7 +388,7 @@ parse()
|
||||
}
|
||||
if (opts & 1 << RBX_PROBEKBD) {
|
||||
i = *(uint8_t *)PTOV(0x496) & 0x10;
|
||||
/* printf("Keyboard: %s\n", i ? "yes" : "no"); */
|
||||
printf("Keyboard: %s\n", i ? "yes" : "no");
|
||||
if (!i)
|
||||
opts |= 1 << RBX_DUAL | 1 << RBX_SERIAL;
|
||||
opts &= ~(1 << RBX_PROBEKBD);
|
||||
|
@ -167,14 +167,14 @@ getstr(void)
|
||||
for (;;) {
|
||||
switch (c = xgetc(0)) {
|
||||
case 0:
|
||||
continue;
|
||||
break;
|
||||
case '\177':
|
||||
case '\b':
|
||||
if (s > cmd) {
|
||||
s--;
|
||||
printf("\b \b");
|
||||
}
|
||||
continue;
|
||||
break;
|
||||
case '\n':
|
||||
case '\r':
|
||||
*s = 0;
|
||||
@ -182,8 +182,8 @@ getstr(void)
|
||||
default:
|
||||
if (s - cmd < sizeof(cmd) - 1)
|
||||
*s++ = c;
|
||||
putchar(c);
|
||||
}
|
||||
putchar(c);
|
||||
}
|
||||
}
|
||||
|
||||
@ -388,7 +388,7 @@ parse()
|
||||
}
|
||||
if (opts & 1 << RBX_PROBEKBD) {
|
||||
i = *(uint8_t *)PTOV(0x496) & 0x10;
|
||||
/* printf("Keyboard: %s\n", i ? "yes" : "no"); */
|
||||
printf("Keyboard: %s\n", i ? "yes" : "no");
|
||||
if (!i)
|
||||
opts |= 1 << RBX_DUAL | 1 << RBX_SERIAL;
|
||||
opts &= ~(1 << RBX_PROBEKBD);
|
||||
|
Loading…
Reference in New Issue
Block a user