Lines Matching refs:sfd
2618 int i, mfd, sfd = -1; local
2637 if ((sfd = open(pty_name, O_RDWR | O_NOCTTY)) < 0)
2643 if (sfd < 0) {
2651 sfd = open(pty_name, O_RDWR | O_NOCTTY, 0);
2652 if (sfd >= 0) {
2653 fchown(sfd, uid, -1);
2654 fchmod(sfd, S_IRUSR | S_IWUSR);
2662 if (sfd < 0)
2667 *slave_fdp = sfd;
2668 if (tcgetattr(sfd, &tios) == 0) {
2674 if (tcsetattr(sfd, TCSAFLUSH, &tios) < 0)