summaryrefslogtreecommitdiff
path: root/openbsd-compat/readpassphrase.c
diff options
context:
space:
mode:
authorColin Watson <cjwatson@debian.org>2009-12-29 21:32:03 +0000
committerColin Watson <cjwatson@debian.org>2009-12-29 21:32:03 +0000
commit04942aa41fa94ec6f2c3ce1d348f600f31bb7c78 (patch)
treeaf8e928bd79d3f2d0219bb5b2c78b573ec31d94c /openbsd-compat/readpassphrase.c
parent9ad7b718d42e43f3a285fcbc8f91193931fce324 (diff)
parent16704d57999d987fb8d9ba53379841a79f016d67 (diff)
import openssh-4.2p1-gsskex-20050926-2.patch
Diffstat (limited to 'openbsd-compat/readpassphrase.c')
-rw-r--r--openbsd-compat/readpassphrase.c7
1 files changed, 5 insertions, 2 deletions
diff --git a/openbsd-compat/readpassphrase.c b/openbsd-compat/readpassphrase.c
index 4ee1be5de..eb060bdbf 100644
--- a/openbsd-compat/readpassphrase.c
+++ b/openbsd-compat/readpassphrase.c
@@ -137,8 +137,11 @@ restart:
137 (void)write(output, "\n", 1); 137 (void)write(output, "\n", 1);
138 138
139 /* Restore old terminal settings and signals. */ 139 /* Restore old terminal settings and signals. */
140 if (memcmp(&term, &oterm, sizeof(term)) != 0) 140 if (memcmp(&term, &oterm, sizeof(term)) != 0) {
141 (void)tcsetattr(input, _T_FLUSH, &oterm); 141 while (tcsetattr(input, _T_FLUSH, &oterm) == -1 &&
142 errno == EINTR)
143 continue;
144 }
142 (void)sigaction(SIGALRM, &savealrm, NULL); 145 (void)sigaction(SIGALRM, &savealrm, NULL);
143 (void)sigaction(SIGHUP, &savehup, NULL); 146 (void)sigaction(SIGHUP, &savehup, NULL);
144 (void)sigaction(SIGINT, &saveint, NULL); 147 (void)sigaction(SIGINT, &saveint, NULL);