termios: fix raw mode initialization

Change-Id: Ibdf0b84fd3ef47c091a670b1cdd00edf2cde196d
Reviewed-on: https://review.haiku-os.org/c/haiku/+/5869
Reviewed-by: Jérôme Duval <[email protected]>
Reviewed-by: waddlesplash <[email protected]>
Tested-by: Commit checker robot <[email protected]>
This commit is contained in:
Zelenoviy
2022-11-30 23:47:12 +00:00
committed by waddlesplash
parent fb69e06195
commit 07ca9bce14
+2
View File
@@ -166,6 +166,8 @@ cfmakeraw(struct termios *termios)
termios->c_lflag &= ~(ECHO | ECHONL | ICANON | ISIG | IEXTEN);
termios->c_cflag &= ~(CSIZE | PARENB);
termios->c_cflag |= CS8;
termios->c_cc[VMIN] = 1; // input is available character by character
termios->c_cc[VTIME] = 0;
}