Commit 74057d2

mo khan <mo.khan@gmail.com>
2021-01-12 23:51:07
enable true raw mode
1 parent cab3253
Changed files (1)
kilo.c
@@ -15,8 +15,9 @@ void enable_raw_mode() {
   atexit(disable_raw_mode);
 
   struct termios raw = orig_termios;
-  raw.c_lflag &= ~(ICRNL | IXON);
+  raw.c_lflag &= ~(BRKINT | ICRNL | INPCK | ISTRIP | IXON);
   raw.c_lflag &= ~(OPOST);
+  raw.c_lflag &= ~(CS8);
   raw.c_lflag &= ~(ECHO | ICANON | IEXTEN | ISIG);
 
   tcsetattr(STDIN_FILENO, TCSAFLUSH, &raw);