Lines Matching refs:tty
142 set_winsize (tty) in set_winsize() argument
143 int tty; in set_winsize()
148 if (ioctl (tty, TIOCGWINSZ, &w) == 0)
149 (void) ioctl (tty, TIOCSWINSZ, &w);
224 get_tty_settings (tty, tiop) in get_tty_settings() argument
225 int tty; in get_tty_settings()
228 set_winsize (tty);
232 if (ioctl (tty, TIOCGETP, &(tiop->sgttyb)) < 0)
237 if (ioctl (tty, TIOCLGET, &(tiop->lflag)) == 0)
242 if (ioctl (tty, TIOCGETC, &(tiop->tchars)) == 0)
247 if (ioctl (tty, TIOCGLTC, &(tiop->ltchars)) == 0)
255 set_tty_settings (tty, tiop) in set_tty_settings() argument
256 int tty; in set_tty_settings()
261 ioctl (tty, TIOCSETN, &(tiop->sgttyb));
269 ioctl (tty, TIOCLSET, &(tiop->lflag));
277 ioctl (tty, TIOCSETC, &(tiop->tchars));
285 ioctl (tty, TIOCSLTC, &(tiop->ltchars));
378 # define GETATTR(tty, tiop) (tcgetattr (tty, tiop)) argument
380 # define SETATTR(tty, tiop) (tcsetattr (tty, TCSANOW, tiop)) argument
382 # define SETATTR(tty, tiop) (tcsetattr (tty, TCSADRAIN, tiop)) argument
387 # define GETATTR(tty, tiop) (ioctl (tty, TCGETA, tiop)) argument
388 # define SETATTR(tty, tiop) (ioctl (tty, TCSETAW, tiop)) argument
475 _get_tty_settings (tty, tiop) in _get_tty_settings() argument
476 int tty; in _get_tty_settings()
483 ioctl_ret = GETATTR (tty, tiop);
508 get_tty_settings (tty, tiop) in get_tty_settings() argument
509 int tty; in get_tty_settings()
512 set_winsize (tty);
514 if (_get_tty_settings (tty, tiop) < 0)
525 _set_tty_settings (tty, tiop) in _set_tty_settings() argument
526 int tty; in _set_tty_settings()
529 while (SETATTR (tty, tiop) < 0)
539 set_tty_settings (tty, tiop) in set_tty_settings() argument
540 int tty; in set_tty_settings()
543 if (_set_tty_settings (tty, tiop) < 0)
553 tcflow (tty, TCOON);
556 tcflow (tty, TCOON); /* Simulate a ^Q. */
559 ioctl (tty, TCXONC, 1); /* Simulate a ^Q. */
634 int tty; local
643 tty = fileno (rl_instream);
645 if (get_tty_settings (tty, &tio) < 0)
657 if (set_tty_settings (tty, &tio) < 0)
677 int tty; in rl_deprep_terminal() local
685 tty = fileno (rl_instream); in rl_deprep_terminal()
692 if (set_tty_settings (tty, &otio) < 0) in rl_deprep_terminal()
784 int tty = fileno (rl_instream); local
798 if (get_tty_settings (tty, &ttybuff) == 0)
827 if (get_tty_settings (tty, &ttybuff) == 0)