apps/system/termcurses/tcurses_vt100.c: Fix an issue where the first curses 'getch()' call sometimes (usually) hangs waiting for a keypress. This bug was introduced when I fixed the keyboard 'paste' overflow error.
This commit is contained in:
parent
806ba4ee83
commit
cb4974cee8
@ -847,9 +847,10 @@ static int tcurses_vt100_getkeycode(FAR struct termcurses_s *dev, FAR int *speci
|
||||
for (x = 0; x < priv->keycount && keycode == -1; x++)
|
||||
{
|
||||
ch = priv->keybuf[x];
|
||||
if (ch == 0)
|
||||
if (ch == 0 && x + 1 == priv->keycount)
|
||||
{
|
||||
continue;
|
||||
priv->keycount = 0;
|
||||
return -1;
|
||||
}
|
||||
|
||||
/* Test for escape sequence */
|
||||
|
Loading…
x
Reference in New Issue
Block a user