Lines Matching refs:ifd
82 prompt_tty(int ifd, int ofd, const char *message, char *response, int echo) in prompt_tty() argument
98 if (tcgetattr(ifd, &tcattr) != 0) { in prompt_tty()
104 if (tcsetattr(ifd, TCSAFLUSH, &tcattr) != 0) { in prompt_tty()
143 pfd.fd = ifd; in prompt_tty()
168 if ((ret = read(ifd, &ch, 1)) < 0) { in prompt_tty()
185 if (tcsetattr(ifd, 0, &tcattr) != 0) { in prompt_tty()
289 int ifd, ofd, ret; in prompt() local
296 ifd = STDIN_FILENO; in prompt()
299 if ((ifd = open("/dev/tty", O_RDWR)) < 0) in prompt()
302 ofd = ifd; in prompt()
304 ret = prompt_tty(ifd, ofd, message, response, echo); in prompt()
305 if (ifd != STDIN_FILENO) in prompt()
306 close(ifd); in prompt()