summaryrefslogtreecommitdiff
path: root/ssh-keyscan.c
diff options
context:
space:
mode:
authorBen Lindstrom <mouring@eviladmin.org>2001-02-15 03:12:08 +0000
committerBen Lindstrom <mouring@eviladmin.org>2001-02-15 03:12:08 +0000
commitf9452513fcf92be881809006ce3c210805d5f2ad (patch)
tree7422ff5a747a6183001292786a74b36adc9453b4 /ssh-keyscan.c
parentd8a9021f3652d8ab99d0fed2460420c3eb4e10a2 (diff)
- deraadt@cvs.openbsd.org 2001/02/12 22:56:09
[clientloop.c packet.c ssh-keyscan.c] deal with EAGAIN/EINTR selects which were skipped
Diffstat (limited to 'ssh-keyscan.c')
-rw-r--r--ssh-keyscan.c7
1 files changed, 5 insertions, 2 deletions
diff --git a/ssh-keyscan.c b/ssh-keyscan.c
index 834649fe..5cd368e9 100644
--- a/ssh-keyscan.c
+++ b/ssh-keyscan.c
@@ -8,7 +8,7 @@
*/
#include "includes.h"
-RCSID("$OpenBSD: ssh-keyscan.c,v 1.15 2001/02/09 09:04:59 itojun Exp $");
+RCSID("$OpenBSD: ssh-keyscan.c,v 1.16 2001/02/12 22:56:10 deraadt Exp $");
#if defined(HAVE_SYS_QUEUE_H) && !defined(HAVE_BOGUS_SYS_QUEUE_H)
#include <sys/queue.h>
@@ -498,7 +498,10 @@ conloop(void)
seltime.tv_sec = seltime.tv_usec = 0;
r = e = read_wait;
- select(maxfd, &r, NULL, &e, &seltime);
+ while (select(maxfd, &r, NULL, &e, &seltime) == -1 &&
+ (errno == EAGAIN || errno == EINTR))
+ ;
+
for (i = 0; i < maxfd; i++)
if (FD_ISSET(i, &e)) {
error("%s: exception!", fdcon[i].c_name);