-/* $OpenBSD: readpassphrase.c,v 1.16 2003/06/17 21:56:23 millert Exp $ */
+/* $OpenBSD: readpassphrase.c,v 1.18 2005/08/08 08:05:34 espie Exp $ */
/*
* Copyright (c) 2000-2002 Todd C. Miller <Todd.Miller@courtesan.com>
/* OPENBSD ORIGINAL: lib/libc/gen/readpassphrase.c */
-#if defined(LIBC_SCCS) && !defined(lint)
-static const char rcsid[] = "$OpenBSD: readpassphrase.c,v 1.16 2003/06/17 21:56:23 millert Exp $";
-#endif /* LIBC_SCCS and not lint */
-
#include "includes.h"
#ifndef HAVE_READPASSPHRASE
#include <termios.h>
+#include <signal.h>
+#include <ctype.h>
+#include <fcntl.h>
#include <readpassphrase.h>
+#include <errno.h>
+#include <string.h>
+#include <unistd.h>
#ifdef TCSASOFT
# define _T_FLUSH (TCSAFLUSH|TCSASOFT)
(void)sigaction(SIGTERM, &saveterm, NULL);
(void)sigaction(SIGTSTP, &savetstp, NULL);
(void)sigaction(SIGTTIN, &savettin, NULL);
+ (void)sigaction(SIGTTOU, &savettou, NULL);
if (input != STDIN_FILENO)
(void)close(input);
errno = save_errno;
return(nr == -1 ? NULL : buf);
}
-
+
#if 0
char *
getpass(const char *prompt)