Lines Matching defs:tty
178 static int tty;
210 (void) ioctl(tty, TCSETAW, &tioorig);
212 (void) tcsetattr(tty, TCSADRAIN, &tioorig);
214 (void) ioctl(tty, TIOCSETP, &sgorig);
419 name_of_tty = x_strdup("/dev/tty");
426 tty = fileno(ttyfp);
452 rc = ioctl(tty, TCGETA, &tioorig);
460 rc = tcgetattr(tty, &tioorig);
468 rc = ioctl(tty, TIOCGETP, &sgorig);
474 failed("get tty settings");
481 rc = ioctl(tty, TCSETAW, &tio);
483 rc = tcsetattr(tty, TCSADRAIN, &tio);
485 rc = ioctl(tty, TIOCSETP, &sg);
488 failed("set tty settings");
501 IGNORE_RC(write(tty, tmpbuf, strlen(tmpbuf)));
505 IGNORE_RC(write(tty, getsize[emu], strlen(getsize[emu])));
512 IGNORE_RC(write(tty, restore[emu], strlen(restore[emu])));
514 /* finally, set the tty's window size */
517 IGNORE_RC(write(tty, getwsize[emu], strlen(getwsize[emu])));
524 SET_TTYSIZE(tty, ts);
525 } else if (ioctl(tty, TIOCGWINSZ, &ts) != -1) {
534 SET_TTYSIZE(tty, ts);
539 rc = ioctl(tty, TCSETAW, &tioorig);
541 rc = tcsetattr(tty, TCSADRAIN, &tioorig);
543 rc = ioctl(tty, TIOCSETP, &sgorig);
546 failed("set tty settings");