12345678910111213141516171819202122232425262728293031323334353637383940414243 |
- --- a/readpassphrase.c (index)
- +++ b/readpassphrase.c (working tree)
- @@ -32,6 +32,16 @@
- #include <unistd.h>
- #include <readpassphrase.h>
-
- +#ifndef TCSASOFT
- +/* If we don't have TCSASOFT define it so that ORing it it below is a no-op. */
- +# define TCSASOFT 0
- +#endif
- +
- +/* SunOS 4.x which lacks _POSIX_VDISABLE, but has VDISABLE */
- +#if !defined(_POSIX_VDISABLE) && defined(VDISABLE)
- +# define _POSIX_VDISABLE VDISABLE
- +#endif
- +
- static volatile sig_atomic_t signo[_NSIG];
-
- static void handler(int);
- @@ -91,8 +91,6 @@ restart:
- memcpy(&term, &oterm, sizeof(term));
- if (!(flags & RPP_ECHO_ON))
- term.c_lflag &= ~(ECHO | ECHONL);
- - if (term.c_cc[VSTATUS] != _POSIX_VDISABLE)
- - term.c_cc[VSTATUS] = _POSIX_VDISABLE;
- (void)tcsetattr(input, TCSAFLUSH|TCSASOFT, &term);
- } else {
- memset(&term, 0, sizeof(term));
- @@ -177,14 +187,6 @@ restart:
- }
-
-
- -char *
- -getpass(const char *prompt)
- -{
- - static char buf[_PASSWORD_LEN + 1];
- -
- - return(readpassphrase(prompt, buf, sizeof(buf), RPP_ECHO_OFF));
- -}
- -
- static void handler(int s)
- {
-
|