Lines Matching defs:ttyfd
656 int fdout, ptyfd, ttyfd, ptymaster;
662 ttyfd = s->ttyfd;
673 close(ttyfd);
680 close(ttyfd);
692 close(ttyfd);
708 pty_make_controlling_tty(&ttyfd, s->tty);
711 if (dup2(ttyfd, 0) < 0)
713 if (dup2(ttyfd, 1) < 0)
715 if (dup2(ttyfd, 2) < 0)
719 close(ttyfd);
754 close(ttyfd);
837 if (s->ttyfd != -1) {
855 else if (s->ttyfd == -1) {
863 if (s->ttyfd != -1)
1292 if (s->ttyfd != -1)
1617 if (s->ttyfd != -1) {
1738 session_setup_sia(pw, s->ttyfd == -1 ? NULL : s->tty);
1938 sessions[id].ttyfd = -1;
2028 if (s->used && s->ttyfd != -1 && strcmp(s->tty, tty) == 0) {
2115 if (s->ttyfd != -1) {
2139 if (!PRIVSEP(pty_allocate(&s->ptyfd, &s->ttyfd, s->tty,
2144 s->ttyfd = -1;
2153 tty_parse_modes(s->ttyfd, &n_bytes);
2393 if (s->ttyfd == -1)
2416 s->ttyfd = -1;
2557 if (s->ttyfd != -1)
2588 if (s->ttyfd != -1)
2615 if (s->ttyfd != -1)
2659 if (s->used && s->ttyfd != -1) {