linux-qubasis
linux oasis port as a qubes template
git clone https://9o.is/git/linux-qubasis.git
0012-readpassphrase-Support-systems-without-VSTATUS-and-T.patch
(1045B)
1 From d36036bbd959091b6442d003128342ed515af01b Mon Sep 17 00:00:00 2001
2 From: Michael Forney <mforney@mforney.org>
3 Date: Sun, 26 Feb 2017 17:01:33 -0800
4 Subject: [PATCH] readpassphrase: Support systems without VSTATUS and TCSASOFT
5
6 ---
7 lib/libc/gen/readpassphrase.c | 6 ++++++
8 1 file changed, 6 insertions(+)
9
10 diff --git a/lib/libc/gen/readpassphrase.c b/lib/libc/gen/readpassphrase.c
11 index a1aeb342b..a50eaf003 100644
12 --- a/lib/libc/gen/readpassphrase.c
13 +++ b/lib/libc/gen/readpassphrase.c
14 @@ -32,6 +32,10 @@
15 #include <unistd.h>
16 #include <readpassphrase.h>
17
18 +#ifndef TCSASOFT
19 +#define TCSASOFT 0
20 +#endif
21 +
22 static volatile sig_atomic_t signo[_NSIG];
23
24 static void handler(int);
25 @@ -81,8 +85,10 @@ restart:
26 memcpy(&term, &oterm, sizeof(term));
27 if (!(flags & RPP_ECHO_ON))
28 term.c_lflag &= ~(ECHO | ECHONL);
29 +#ifdef VSTATUS
30 if (term.c_cc[VSTATUS] != _POSIX_VDISABLE)
31 term.c_cc[VSTATUS] = _POSIX_VDISABLE;
32 +#endif
33 (void)tcsetattr(input, TCSAFLUSH|TCSASOFT, &term);
34 } else {
35 memset(&term, 0, sizeof(term));
36 --
37 2.12.2
38