getty: explain every bit in termios; remove redundant stuff in termios_final

Signed-off-by: Denys Vlasenko <vda.linux@googlemail.com>
This commit is contained in:
Denys Vlasenko
2011-01-26 03:26:38 +01:00
parent ea023eacad
commit d8494934a7
2 changed files with 35 additions and 39 deletions

View File

@ -53,6 +53,7 @@ int resize_main(int argc UNUSED_PARAM, char **argv UNUSED_PARAM)
*/
fprintf(stderr, ESC"7" ESC"[r" ESC"[999;999H" ESC"[6n");
alarm(3); /* Just in case terminal won't answer */
//BUG: death by signal won't restore termios
scanf(ESC"[%hu;%huR", &w.ws_row, &w.ws_col);
fprintf(stderr, ESC"8");