Don't use FLUSH when switching modes in rline
This commit is contained in:
parent
47500c833f
commit
0918776d00
4
src/vendor/rline.c
vendored
4
src/vendor/rline.c
vendored
@ -2022,12 +2022,12 @@ static void set_unbuffered(void) {
|
||||
_EOF = old.c_cc[VEOF];
|
||||
struct termios new = old;
|
||||
new.c_lflag &= (~ICANON & ~ECHO & ~ISIG);
|
||||
tcsetattr(STDOUT_FILENO, TCSAFLUSH, &new);
|
||||
tcsetattr(STDOUT_FILENO, TCSADRAIN, &new);
|
||||
if (wcwidth(0x3042) != 2) setlocale(LC_CTYPE, "");
|
||||
}
|
||||
|
||||
static void set_buffered(void) {
|
||||
tcsetattr(STDOUT_FILENO, TCSAFLUSH, &old);
|
||||
tcsetattr(STDOUT_FILENO, TCSADRAIN, &old);
|
||||
}
|
||||
#else
|
||||
static unsigned int _INTR = 3;
|
||||
|
Loading…
Reference in New Issue
Block a user