workaround not having a real readline-ish in debug shell

This commit is contained in:
Kevin Lange 2014-03-26 21:41:58 -07:00
parent 37f2a70ab5
commit 6f4d55aeff

View File

@ -76,10 +76,19 @@ static int debug_shell_readline(fs_node_t * dev, char * linebuf, int max) {
read--;
linebuf[read] = 0;
}
continue;
} else if (buf[0] < ' ') {
switch (buf[0]) {
case 0x0C: /* ^L */
/* Should reset display here */
break;
default:
/* do nothing */
break;
}
} else {
fs_printf(dev, "%c", buf[0]);
read += r;
}
fs_printf(dev, "%c", buf[0]);
read += r;
}
set_buffered(dev);
return read;