Searched refs:ttyfd (Results 1 - 13 of 13) sorted by relevance

/freebsd-9.3-release/bin/pax/
H A Dtty_subs.c70 int ttyfd; local
72 if ((ttyfd = open(DEVTTY, O_RDWR)) >= 0) {
73 if ((ttyoutf = fdopen(ttyfd, "w")) != NULL) {
74 if ((ttyinf = fdopen(ttyfd, "r")) != NULL)
78 (void)close(ttyfd);
/freebsd-9.3-release/crypto/openssh/
H A Dsshpty.c64 pty_allocate(int *ptyfd, int *ttyfd, char *namebuf, size_t namebuflen) argument
70 i = openpty(ptyfd, ttyfd, NULL, NULL, NULL);
75 name = ttyname(*ttyfd);
99 pty_make_controlling_tty(int *ttyfd, const char *tty) argument
122 ioctl(*ttyfd, TCSETCTTY, NULL);
126 close(*ttyfd);
127 *ttyfd = fd;
153 if (ioctl(*ttyfd, TIOCSCTTY, NULL) < 0)
170 close(*ttyfd);
171 *ttyfd
[all...]
H A Dreadpass.c122 int rppflags, use_askpass = 0, ttyfd; local
134 ttyfd = open(_PATH_TTY, O_RDWR);
135 if (ttyfd >= 0)
136 close(ttyfd);
H A Dsession.h41 int ptyfd, ttyfd, ptymaster; member in struct:Session
H A Dsession.c675 int fdout, ptyfd, ttyfd, ptymaster; local
681 ttyfd = s->ttyfd;
692 close(ttyfd);
699 close(ttyfd);
711 close(ttyfd);
727 pty_make_controlling_tty(&ttyfd, s->tty);
730 if (dup2(ttyfd, 0) < 0)
732 if (dup2(ttyfd, 1) < 0)
734 if (dup2(ttyfd,
[all...]
H A Dmonitor.c1424 if (s->ttyfd != -1) {
1447 res = pty_allocate(&s->ptyfd, &s->ttyfd, s->tty, sizeof(s->tty));
1456 if (dup2(s->ttyfd, 0) == -1)
1471 mm_send_fd(sock, s->ttyfd) == -1)
1481 close(s->ttyfd);
1482 s->ttyfd = s->ptyfd;
1486 debug3("%s: tty %s ptyfd %d", __func__, s->tty, s->ttyfd);
H A Dmonitor_wrap.c701 mm_pty_allocate(int *ptyfd, int *ttyfd, char *namebuf, size_t namebuflen) argument
743 (*ttyfd = mm_receive_fd(pmonitor->m_recvfd)) == -1)
755 if (s->ttyfd == -1)
768 s->ttyfd = -1;
H A Dconfigure11472 int fd, ptyfd, ttyfd, status;
11486 openpty(&ptyfd, &ttyfd, NULL, NULL, NULL);
/freebsd-9.3-release/sbin/conscontrol/
H A Dconscontrol.c158 int ttyfd; local
160 ttyfd = open(devnam, O_RDONLY);
161 if (ttyfd == -1)
163 if (ioctl(ttyfd, TIOCCONS, &flag) == -1)
166 close(ttyfd);
/freebsd-9.3-release/bin/sh/
H A Djobs.c89 static int ttyfd = -1; variable
125 if (ttyfd != -1)
126 close(ttyfd);
127 if ((ttyfd = open(_PATH_TTY, O_RDWR)) < 0) {
131 if (i > 2 || (ttyfd = fcntl(i, F_DUPFD, 10)) < 0)
134 if (ttyfd < 10) {
139 if ((i = fcntl(ttyfd, F_DUPFD, 10)) < 0) {
140 close(ttyfd);
141 ttyfd = -1;
144 close(ttyfd);
[all...]
/freebsd-9.3-release/gnu/usr.bin/patch/
H A Dutil.c251 int ttyfd; local
264 } else if ((ttyfd = open(_PATH_TTY, 2)) >= 0 && isatty(ttyfd)) {
266 write(ttyfd, buf, strlen(buf));
267 r = read(ttyfd, buf, buf_size);
268 Close(ttyfd);
/freebsd-9.3-release/crypto/heimdal/appl/telnet/telnetd/
H A Dsys_term.c160 static int ttyfd = -1; variable
182 tcgetattr(ttyfd, &termbuf);
198 tcsetattr(ttyfd, TCSANOW, &termbuf);
851 ttyfd = t;
/freebsd-9.3-release/contrib/ntp/ntpd/
H A Drefclock_oncore.c272 int ttyfd; /* TTY file descriptor */ member in struct:instance
719 instance->ttyfd = fd1;
791 close(instance->ttyfd);
793 if ((instance->ppsfd != -1) && (instance->ppsfd != instance->ttyfd))
3534 write(instance->ttyfd, cp, n);
3549 write(instance->ttyfd, cp, n);
3758 fd = instance->ttyfd;

Completed in 140 milliseconds