]> err.no Git - util-linux/commitdiff
login: replace termio with termios interface
authorSamuel Thibault <samuel.thibault@ens-lyon.org>
Thu, 3 Jan 2008 15:40:48 +0000 (16:40 +0100)
committerKarel Zak <kzak@redhat.com>
Thu, 3 Jan 2008 15:40:48 +0000 (16:40 +0100)
Signed-off-by: Karel Zak <kzak@redhat.com>
login-utils/login.c

index 9b02358c4b5284a31eace2c61db0346cad1cfbf0..d40381d4ef0c95c67c6ef5e0f3fe4d5ee643ad89 100644 (file)
@@ -1308,12 +1308,12 @@ getloginname(void) {
 
 static void
 timedout2(int sig) {
-       struct termio ti;
+       struct termios ti;
 
        /* reset echo */
-       ioctl(0, TCGETA, &ti);
+       tcgetattr(0, &ti);
        ti.c_lflag |= ECHO;
-       ioctl(0, TCSETA, &ti);
+       tcsetattr(0, TCSANOW, &ti);
        exit(0);                        /* %% */
 }